summaryrefslogtreecommitdiff
path: root/src/ui
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/util.c3
-rw-r--r--src/ui/window.c4
2 files changed, 6 insertions, 1 deletions
diff --git a/src/ui/util.c b/src/ui/util.c
index 98f0fb18..9ac18881 100644
--- a/src/ui/util.c
+++ b/src/ui/util.c
@@ -868,7 +868,8 @@ void updateValueInput_Widget(iWidget *d, const char *title, const char *prompt)
868 868
869static iBool messageHandler_(iWidget *msg, const char *cmd) { 869static iBool messageHandler_(iWidget *msg, const char *cmd) {
870 /* Almost any command dismisses the sheet. */ 870 /* Almost any command dismisses the sheet. */
871 if (!(equal_Command(cmd, "media.updated") || equal_Command(cmd, "document.request.updated"))) { 871 if (!(equal_Command(cmd, "media.updated") || equal_Command(cmd, "document.request.updated") ||
872 startsWith_CStr(cmd, "window."))) {
872 destroy_Widget(msg); 873 destroy_Widget(msg);
873 } 874 }
874 return iFalse; 875 return iFalse;
diff --git a/src/ui/window.c b/src/ui/window.c
index 63f19e3f..4418e61f 100644
--- a/src/ui/window.c
+++ b/src/ui/window.c
@@ -680,6 +680,10 @@ static iBool handleWindowEvent_Window_(iWindow *d, const SDL_WindowEvent *ev) {
680 return iTrue; 680 return iTrue;
681 case SDL_WINDOWEVENT_FOCUS_GAINED: 681 case SDL_WINDOWEVENT_FOCUS_GAINED:
682 d->focusGainedAt = SDL_GetTicks(); 682 d->focusGainedAt = SDL_GetTicks();
683 postCommand_App("window.focus.gained");
684 return iFalse;
685 case SDL_WINDOWEVENT_FOCUS_LOST:
686 postCommand_App("window.focus.lost");
683 return iFalse; 687 return iFalse;
684 default: 688 default:
685 break; 689 break;