AmendHub

Download:

jcs

/

wallops

/

amendments

/

106

main: Cancel notification and show focusable in all mouse handling


jcs made amendment 106 2 months ago
--- main.c Fri Sep 13 16:09:49 2024 +++ main.c Fri Sep 13 20:39:49 2024 @@ -135,6 +135,11 @@ main(void) event_in = FindWindow(event.where, &event_win); found_focusable = focusable_find(event_win); + if (event_win != FrontWindow() && found_focusable) { + cancel_notification(); + focusable_show(found_focusable); + } + switch (event_in) { case inMenuBar: handle_menu(MenuSelect(event.where)); @@ -146,10 +151,6 @@ main(void) DragWindow(event_win, event.where, &screenBits.bounds); break; case inGrow: - if (event_win != FrontWindow() && found_focusable) { - cancel_notification(); - focusable_show(found_focusable); - } if (found_focusable && found_focusable->resize) found_focusable->resize(found_focusable, &event); break; @@ -158,10 +159,6 @@ main(void) focusable_close(found_focusable); break; case inContent: - if (event_win != FrontWindow() && found_focusable) { - cancel_notification(); - focusable_show(found_focusable); - } if (found_focusable && found_focusable->mouse_down) found_focusable->mouse_down(found_focusable, &event); break;