🎨 ProUI cleanup
This commit is contained in:
parent
c3fe4abd44
commit
290a55ced1
|
@ -19,13 +19,13 @@
|
|||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* Bed Level Tools for Pro UI
|
||||
* Extended by: Miguel A. Risco-Castillo (MRISCOC)
|
||||
* Version: 2.1.0
|
||||
* Date: 2022/08/27
|
||||
*
|
||||
*
|
||||
* Based on the original work of: Henri-J-Norden
|
||||
* https://github.com/Jyers/Marlin/pull/126
|
||||
*
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
* Extended by: Miguel A. Risco-Castillo (MRISCOC)
|
||||
* Version: 2.1.0
|
||||
* Date: 2022/08/27
|
||||
*
|
||||
*
|
||||
* Based on the original work of: Henri-J-Norden
|
||||
* https://github.com/Jyers/Marlin/pull/126
|
||||
*
|
||||
|
|
|
@ -399,7 +399,7 @@ void MenuClass::onScroll(bool dir) {
|
|||
}
|
||||
|
||||
void MenuClass::onClick() {
|
||||
if (MenuItems[selected]->onClick != nullptr) (*MenuItems[selected]->onClick)();
|
||||
if (MenuItems[selected]->onClick != nullptr) (*MenuItems[selected]->onClick)();
|
||||
}
|
||||
|
||||
CustomMenuItemClass *MenuClass::SelectedItem() {
|
||||
|
@ -410,8 +410,8 @@ CustomMenuItemClass** MenuClass::Items() {
|
|||
return MenuItems;
|
||||
}
|
||||
|
||||
int8_t MenuClass::count() {
|
||||
return MenuItemCount;
|
||||
int8_t MenuClass::count() {
|
||||
return MenuItemCount;
|
||||
};
|
||||
|
||||
/* MenuItem Class ===========================================================*/
|
||||
|
@ -510,7 +510,7 @@ MenuItemClass* MenuItemAdd(uint8_t cicon, uint8_t id, uint16_t x1, uint16_t y1,
|
|||
return MenuItemAdd(menuitem);
|
||||
}
|
||||
else return nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
MenuItemClass* EditItemAdd(uint8_t cicon, const char * const text, OnDrawItem ondraw, OnClickItem onclick, void* val) {
|
||||
if (MenuItemCount < MenuItemTotal) {
|
||||
|
|
|
@ -81,9 +81,9 @@ void Goto_PrintStats() {
|
|||
|
||||
// Print Stats Reset popup
|
||||
void Popup_ResetStats() { DWIN_Popup_ConfirmCancel(ICON_Info_0, GET_TEXT_F(MSG_RESET_STATS)); }
|
||||
void OnClick_ResetStats() {
|
||||
void OnClick_ResetStats() {
|
||||
if (HMI_flag.select_flag) PrintStatsClass::Reset();
|
||||
HMI_ReturnScreen();
|
||||
HMI_ReturnScreen();
|
||||
}
|
||||
void PrintStatsReset() { Goto_Popup(Popup_ResetStats, OnClick_ResetStats); }
|
||||
|
||||
|
|
Loading…
Reference in a new issue