]> uap-core.de Git - uwplayer.git/commitdiff
add -w option for disabling the adjust window size setting
authorOlaf Wintermann <olaf.wintermann@gmail.com>
Sat, 20 Sep 2025 21:18:16 +0000 (23:18 +0200)
committerOlaf Wintermann <olaf.wintermann@gmail.com>
Sat, 20 Sep 2025 21:18:16 +0000 (23:18 +0200)
application/main.c

index 83724742b7c2c00626449d954c44e4a6b438225c..8cf02c45f686ca95d034187e4725376f90f05d35 100644 (file)
@@ -108,7 +108,7 @@ int main(int argc, char** argv) {
     
     PlaybackMode playback = PLAYBACK_STOP;
     bool fullscreen = FALSE;
-    bool adjust_window_size = FALSE;
+    bool disable_adjust_window_size = FALSE;
     bool single_instance = FALSE;
     
     bool file_args = 0;
@@ -152,8 +152,8 @@ int main(int argc, char** argv) {
                                 break;
                             }
                             case 'w': {
-                                // adjust Window size
-                                adjust_window_size = TRUE;
+                                // disable adjust Window size
+                                disable_adjust_window_size = TRUE;
                                 break;
                             }
                             case 'f': {
@@ -205,6 +205,10 @@ int main(int argc, char** argv) {
     
     MainWindow *window = WindowCreate(display);
     toplevel_window = window->window;
+    if(disable_adjust_window_size) {
+        window->adjustWindowSize = FALSE;
+        XtVaSetValues(window->viewAdjustWindowSize, XmNset, FALSE, NULL);
+    }
     
     // random numbers used for creating tmp dirs and for random playback
     srand(time(NULL));