File tree 3 files changed +15
-6
lines changed
packages/project-editor/lvgl
3 files changed +15
-6
lines changed Original file line number Diff line number Diff line change @@ -467,6 +467,19 @@ export class LVGLBuild extends Build {
467
467
`void *flowState = lv_event_get_user_data(e);`
468
468
) ;
469
469
470
+ build . line ( "" ) ;
471
+
472
+ if ( widget . hasEventHandler ) {
473
+ widget . buildEventHandler ( build ) ;
474
+ }
475
+
476
+ if (
477
+ widget . eventHandlers . length > 0 &&
478
+ widget . hasEventHandler
479
+ ) {
480
+ build . line ( "" ) ;
481
+ }
482
+
470
483
for ( const eventHandler of widget . eventHandlers ) {
471
484
if (
472
485
eventHandler . eventName == "CHECKED" ||
@@ -537,10 +550,6 @@ export class LVGLBuild extends Build {
537
550
build . line ( "}" ) ;
538
551
}
539
552
540
- if ( widget . hasEventHandler ) {
541
- widget . buildEventHandler ( build ) ;
542
- }
543
-
544
553
build . unindent ( ) ;
545
554
build . line ( "}" ) ;
546
555
build . line ( "" ) ;
Original file line number Diff line number Diff line change @@ -751,7 +751,7 @@ export class LVGLWidget extends Widget {
751
751
propertyGridGroup : generalGroup ,
752
752
hideInPropertyGrid : ( widget : LVGLWidget ) =>
753
753
ProjectEditor . getProject ( widget ) . lvglGroups . groups . length ==
754
- 0
754
+ 0 || widget instanceof LVGLScreenWidget
755
755
} ,
756
756
{
757
757
name : "groupIndex" ,
Original file line number Diff line number Diff line change @@ -144,7 +144,7 @@ export class LVGLScreenWidget extends LVGLWidget {
144
144
ProjectEditor . PageClass . classInfo
145
145
) as Page ;
146
146
147
- build . line ( "if (event == LV_EVENT_SCREEN_LOADED ) {" ) ;
147
+ build . line ( "if (event == LV_EVENT_SCREEN_LOAD_START ) {" ) ;
148
148
build . indent ( ) ;
149
149
150
150
for ( const group of allGroups ) {
You can’t perform that action at this time.
0 commit comments