ui, scaling in sdl window mode (ATM hidden)
authorkub <derkub@gmail.com>
Thu, 6 May 2021 20:19:16 +0000 (22:19 +0200)
committerkub <derkub@gmail.com>
Thu, 6 May 2021 20:19:38 +0000 (22:19 +0200)
platform/common/menu_pico.c
platform/common/plat_sdl.c
platform/linux/menu.c [new file with mode: 0644]

index f1cc9fc..6a6da39 100644 (file)
@@ -78,8 +78,7 @@ static const char *men_dummy[] = { NULL };
 #elif defined(PANDORA)
 #include <platform/pandora/menu.c>
 #else
-#define MENU_OPTIONS_GFX
-#define MENU_OPTIONS_ADV
+#include <platform/linux/menu.c>
 #endif
 
 static void make_bg(int no_scale, int from_screen)
index 2cdb197..5edeb79 100644 (file)
@@ -230,7 +230,7 @@ void plat_video_loop_prepare(void)
        // take over any new vout settings XXX ask plat_sdl for scaling instead!
        plat_sdl_change_video_mode(g_menuscreen_w, g_menuscreen_h, 0);
        // switch over to scaled output if available
-       if (plat_sdl_overlay != NULL || plat_sdl_gl_active) {
+       if (plat_sdl_overlay != NULL || plat_sdl_gl_active || currentConfig.scaling != EOPT_SCALE_NONE) {
                g_screen_width = 320;
                g_screen_height = 240;
                g_screen_ppitch = g_screen_width;
diff --git a/platform/linux/menu.c b/platform/linux/menu.c
new file mode 100644 (file)
index 0000000..b9bf4ce
--- /dev/null
@@ -0,0 +1,16 @@
+#include "../libpicofe/gp2x/plat_gp2x.h"
+
+// ------------ gfx options menu ------------
+
+
+const char *men_scaling_opts[] = { "OFF", "ON", NULL };
+
+#define MENU_OPTIONS_GFX \
+       // mee_enum      ("screen scaling",           MA_OPT_SCALING,        currentConfig.scaling, men_scaling_opts), \
+
+#define MENU_OPTIONS_ADV
+
+void linux_menu_init(void)
+{
+}
+