bazzite/spec_files/anaconda/bazzite.patch
2024-11-09 10:21:21 -08:00

35 lines
1.3 KiB
Diff

diff -Naur a/pyanaconda/display.py b/pyanaconda/display.py
--- a/pyanaconda/display.py
+++ b/pyanaconda/display.py
@@ -391,6 +391,13 @@
if not anaconda.gui_startup_failed:
if options.runres and anaconda.gui_mode and not flags.use_rd:
def on_mutter_ready(observer):
+ # Get product name
+ with open("/sys/devices/virtual/dmi/id/product_name") as f:
+ dmi = f.read().strip()
+
+ if "Jupiter" in dmi or "Galileo" in dmi or "NEXT" in dmi:
+ options.runres = "1280x800"
+
set_resolution(options.runres)
observer.disconnect()
diff -Naur a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
--- a/pyanaconda/ui/gui/__init__.py
+++ b/pyanaconda/ui/gui/__init__.py
@@ -576,6 +576,13 @@
if not primary_monitor:
return
+ with open("/sys/devices/virtual/dmi/id/product_name") as f:
+ dmi = f.read().strip()
+
+ if "Jupiter" in dmi or "Galileo" in dmi or "NEXT" in dmi:
+ util.setenv("GDK_SCALE", "1")
+ return
+
monitor_geometry = primary_monitor.get_geometry()
monitor_scale = primary_monitor.get_scale_factor()
monitor_width_mm = primary_monitor.get_width_mm()