diff --git a/android/app/src/main/res/mipmap-hdpi/ic_launcher.png b/android/app/src/main/res/mipmap-hdpi/ic_launcher.png index a1b741f..316ff12 100644 Binary files a/android/app/src/main/res/mipmap-hdpi/ic_launcher.png and b/android/app/src/main/res/mipmap-hdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/mipmap-mdpi/ic_launcher.png b/android/app/src/main/res/mipmap-mdpi/ic_launcher.png index 9152b45..1b29daa 100644 Binary files a/android/app/src/main/res/mipmap-mdpi/ic_launcher.png and b/android/app/src/main/res/mipmap-mdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png index cf83f60..ed33a5d 100644 Binary files a/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png and b/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png index 366a857..c6d0b39 100644 Binary files a/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png and b/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png index d1c7f75..a1842df 100644 Binary files a/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png and b/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/images/icon.png b/images/icon.png index ded8c25..4b71154 100644 Binary files a/images/icon.png and b/images/icon.png differ diff --git a/lib/main.dart b/lib/main.dart index f4f5ec0..3f7ceb2 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -383,11 +383,17 @@ sed -i -E "s@^(VNC_RESOLUTION)=.*@\\1=${w}x${h}@" \$(command -v startvnc)"""); ]), const SizedBox.square(dimension: 8), SwitchListTile(title: const Text("默认使用Termux X11"), subtitle: const Text("不使用VNC。重启生效"), value: Util.getGlobal("useX11") as bool, onChanged:(value) { - G.prefs.setBool("useX11", value); - if (!value && Util.getGlobal("dri3")) { - G.prefs.setBool("dri3", false); - } - setState(() {}); + if (!context.mounted) return; + ScaffoldMessenger.of(context).hideCurrentSnackBar(); + ScaffoldMessenger.of(context).showSnackBar( + const SnackBar(content: Text("GXDE版本暂未适配VNC")) + ); + return; + // G.prefs.setBool("useX11", value); + // if (!value && Util.getGlobal("dri3")) { + // G.prefs.setBool("dri3", false); + // } + // setState(() {}); },), const SizedBox.square(dimension: 16), const Divider(height: 2, indent: 8, endIndent: 8), diff --git a/lib/workflow.dart b/lib/workflow.dart index d315b78..da28d90 100644 --- a/lib/workflow.dart +++ b/lib/workflow.dart @@ -117,7 +117,7 @@ class Util { case "isHidpiEnabled" : return b ? G.prefs.getBool(key)! : (value){G.prefs.setBool(key, value); return value;}(false); case "isJpEnabled" : return b ? G.prefs.getBool(key)! : (value){G.prefs.setBool(key, value); return value;}(false); case "useAvnc" : return b ? G.prefs.getBool(key)! : (value){G.prefs.setBool(key, value); return value;}(true); - case "useX11" : return b ? G.prefs.getBool(key)! : (value){G.prefs.setBool(key, value); return value;}(false); + case "useX11" : return true; // b ? G.prefs.getBool(key)! : (value){G.prefs.setBool(key, value); return value;}(false); case "defaultFFmpegCommand" : return b ? G.prefs.getString(key)! : (value){G.prefs.setString(key, value); return value;}("-hide_banner -an -max_delay 1000000 -r 30 -f android_camera -camera_index 0 -i 0:0 -vf scale=iw/2:-1 -rtsp_transport udp -f rtsp rtsp://127.0.0.1:8554/stream"); case "defaultVirglCommand" : return b ? G.prefs.getString(key)! : (value){G.prefs.setString(key, value); return value;}("--socket-path=\$CONTAINER_DIR/tmp/.virgl_test"); case "defaultVirglOpt" : return b ? G.prefs.getString(key)! : (value){G.prefs.setString(key, value); return value;}("GALLIUM_DRIVER=virpipe"); @@ -142,7 +142,7 @@ class Util { return m[key]; } switch (key) { - case "name" : return (value){addCurrentProp(key, value); return value;}("Debian Bookworm"); + case "name" : return (value){addCurrentProp(key, value); return value;}("GXDE OS"); case "boot" : return (value){addCurrentProp(key, value); return value;}(D.boot); case "vnc" : return (value){addCurrentProp(key, value); return value;}("startnovnc &"); case "vncUrl" : return (value){addCurrentProp(key, value); return value;}("http://localhost:36082/vnc.html?host=localhost&port=36082&autoconnect=true&resize=remote&password=12345678");