Skip to content

Commit 83fc949

Browse files
committed
fix: cursor position should be updated before handle widget events
1 parent 09d33ab commit 83fc949

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -639,6 +639,7 @@ void LCUI_InitBase(void)
639639
LCUI_InitEvent();
640640
LCUI_InitFontLibrary();
641641
LCUI_InitTimer();
642+
LCUI_InitCursor();
642643
LCUI_InitWidget();
643644
LCUI_InitMetrics();
644645
}
@@ -651,7 +652,6 @@ void LCUI_Init(void)
651652
LCUI_InitMouseDriver();
652653
LCUI_InitKeyboardDriver();
653654
LCUI_InitKeyboard();
654-
LCUI_InitCursor();
655655
LCUI_InitIME();
656656

657657
switch (LCUI_GetAppId()) {
@@ -682,8 +682,8 @@ int LCUI_Destroy(void)
682682
LCUI_FreeApp();
683683
LCUI_FreeIME();
684684
LCUI_FreeKeyboard();
685-
LCUI_FreeCursor();
686685
LCUI_FreeWidget();
686+
LCUI_FreeCursor();
687687
LCUI_FreeFontLibrary();
688688
LCUI_FreeTimer();
689689
LCUI_FreeEvent();

0 commit comments

Comments
 (0)