summaryrefslogtreecommitdiff
path: root/src/app.c
diff options
context:
space:
mode:
authorJaakko Keränen <jaakko.keranen@iki.fi>2021-05-15 22:38:13 +0300
committerJaakko Keränen <jaakko.keranen@iki.fi>2021-05-15 22:38:13 +0300
commitafce90c9f6b52db97de29824d1afd1a0742550df (patch)
treec22eeafe577995215ef6edf448a35f8d8328cb8d /src/app.c
parentd268545d12db5b02ee5975acb311d5b3cd875d6a (diff)
Mobile: Various improvements and fixes
- fill the safe area with theme background - don't set button hover states if dragging/scrolling - edge-draggable widgets must be flagged as such - Preferences top panel offset matches sibling panels' offset - allow toolbar to unhide when document is not scrollable
Diffstat (limited to 'src/app.c')
-rw-r--r--src/app.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/app.c b/src/app.c
index b80953a1..64348930 100644
--- a/src/app.c
+++ b/src/app.c
@@ -1056,7 +1056,14 @@ void processEvents_App(enum iAppEventMode eventMode) {
1056 } 1056 }
1057 continue; 1057 continue;
1058 } 1058 }
1059 else if (ev.type == SDL_USEREVENT && ev.user.code == arrange_UserEventCode) { 1059 d->lastEventTime = SDL_GetTicks();
1060 if (d->isIdling) {
1061// printf("[App] ...woke up\n");
1062// fflush(stdout);
1063 }
1064 d->isIdling = iFalse;
1065#endif
1066 if (ev.type == SDL_USEREVENT && ev.user.code == arrange_UserEventCode) {
1060 printf("[App] rearrange\n"); 1067 printf("[App] rearrange\n");
1061 resize_Window(d->window, -1, -1); 1068 resize_Window(d->window, -1, -1);
1062 iForIndices(i, d->window->roots) { 1069 iForIndices(i, d->window->roots) {
@@ -1073,13 +1080,6 @@ void processEvents_App(enum iAppEventMode eventMode) {
1073// postRefresh_App(); 1080// postRefresh_App();
1074 continue; 1081 continue;
1075 } 1082 }
1076 d->lastEventTime = SDL_GetTicks();
1077 if (d->isIdling) {
1078// printf("[App] ...woke up\n");
1079// fflush(stdout);
1080 }
1081 d->isIdling = iFalse;
1082#endif
1083 gotEvents = iTrue; 1083 gotEvents = iTrue;
1084 /* Keyboard modifier mapping. */ 1084 /* Keyboard modifier mapping. */
1085 if (ev.type == SDL_KEYDOWN || ev.type == SDL_KEYUP) { 1085 if (ev.type == SDL_KEYDOWN || ev.type == SDL_KEYUP) {
@@ -1508,6 +1508,7 @@ static void updateFontButton_(iLabelWidget *button, int font) {
1508 1508
1509static iBool handlePrefsCommands_(iWidget *d, const char *cmd) { 1509static iBool handlePrefsCommands_(iWidget *d, const char *cmd) {
1510 if (equal_Command(cmd, "prefs.dismiss") || equal_Command(cmd, "preferences")) { 1510 if (equal_Command(cmd, "prefs.dismiss") || equal_Command(cmd, "preferences")) {
1511 setupSheetTransition_Widget(d, iFalse);
1511 setUiScale_Window(get_Window(), 1512 setUiScale_Window(get_Window(),
1512 toFloat_String(text_InputWidget(findChild_Widget(d, "prefs.uiscale")))); 1513 toFloat_String(text_InputWidget(findChild_Widget(d, "prefs.uiscale"))));
1513#if defined (LAGRANGE_ENABLE_DOWNLOAD_EDIT) 1514#if defined (LAGRANGE_ENABLE_DOWNLOAD_EDIT)