File tree Expand file tree Collapse file tree 2 files changed +5
-9
lines changed Expand file tree Collapse file tree 2 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -68,13 +68,6 @@ class BraccioClass {
68
68
bool connected (int joint_index) {
69
69
return _connected[joint_index];
70
70
}
71
- void createMenu () {
72
- if (_customMenu != NULL ) {
73
- _customMenu ();
74
- } else {
75
- defaultMenu ();
76
- }
77
- }
78
71
79
72
int getKey ();
80
73
void connectJoystickTo (lv_obj_t * obj);
Original file line number Diff line number Diff line change @@ -109,8 +109,11 @@ bool BraccioClass::begin(voidFuncPtr customMenu) {
109
109
p_objGroup = lv_group_create ();
110
110
lv_group_set_default (p_objGroup);
111
111
112
- _customMenu = customMenu;
113
- createMenu ();
112
+ if (customMenu) {
113
+ customMenu ();
114
+ } else {
115
+ defaultMenu ();
116
+ }
114
117
115
118
gfx.fillScreen (TFT_BLACK);
116
119
gfx.println (" \n\n Please\n connect\n power" );
You can’t perform that action at this time.
0 commit comments