From b395ce2553d8a52f80add52ff942ae662a61fd25 Mon Sep 17 00:00:00 2001 From: Juno Anna Marx <56306628+junomarx@users.noreply.github.com> Date: Thu, 21 Mar 2024 18:12:24 +0100 Subject: [PATCH 1/3] Add gnome shell compatibility for versions 40-42 --- threefingerwindowmove@do.sch.dev.gmail.com/metadata.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/threefingerwindowmove@do.sch.dev.gmail.com/metadata.json b/threefingerwindowmove@do.sch.dev.gmail.com/metadata.json index c81990f..dea826b 100644 --- a/threefingerwindowmove@do.sch.dev.gmail.com/metadata.json +++ b/threefingerwindowmove@do.sch.dev.gmail.com/metadata.json @@ -3,5 +3,5 @@ "description": "Allows moving windows around with a three finger trackpad gesture (Wayland only)", "url": "https://github.com/do-sch/gnome-shell-touchpad-window-move", "uuid": "threefingerwindowmove@do.sch.dev.gmail.com", - "shell-version": ["3.32", "3.34", "3.36", "3.38"] + "shell-version": ["3.32", "3.34", "3.36", "3.38", "40", "41", "42"] } From d741c8d1a1bcb25e0e150e0cd0d48348cd694632 Mon Sep 17 00:00:00 2001 From: Juno Anna Marx <56306628+junomarx@users.noreply.github.com> Date: Thu, 21 Mar 2024 18:16:05 +0100 Subject: [PATCH 2/3] Fix preferences for gnome-shell >=40 --- .../prefs.js | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/threefingerwindowmove@do.sch.dev.gmail.com/prefs.js b/threefingerwindowmove@do.sch.dev.gmail.com/prefs.js index be26093..5a3ece9 100644 --- a/threefingerwindowmove@do.sch.dev.gmail.com/prefs.js +++ b/threefingerwindowmove@do.sch.dev.gmail.com/prefs.js @@ -13,7 +13,10 @@ function buildPrefsWidget() { let frame = new Gtk.Frame(); frame.set_label("Gesture Options"); frame.set_valign(Gtk.Align.START); - frame.margin = 20; + frame.set_margin_top(20); + frame.set_margin_bottom(20); + frame.set_margin_start(20); + frame.set_margin_end(20); // Grid to place all the widgets let layout = new Gtk.Grid({ @@ -21,9 +24,12 @@ function buildPrefsWidget() { column_spacing: 20, row_homogeneous: true, row_spacing: 5, - margin: 20 + margin_top: 20, + margin_bottom: 20, + margin_start: 20, + margin_end: 20 }); - frame.add(layout); + frame.set_child(layout); // Widgets let accelLabel = new Gtk.Label({label: "Acceleration"}); @@ -78,7 +84,7 @@ function buildPrefsWidget() { layout.attach(summarizeLabel, 0, 2, 1, 1); layout.attach(summarizeSwitch, 1, 2, 1, 1); - frame.show_all(); + //frame.show_all(); return frame; } From 5c91f155f3ff8f0021bcbec942f864f13b52c8d4 Mon Sep 17 00:00:00 2001 From: Juno Anna Marx <56306628+junomarx@users.noreply.github.com> Date: Thu, 21 Mar 2024 18:22:39 +0100 Subject: [PATCH 3/3] reassign existing gnome gestures from 3 to 4 fingers --- .../swipe3to4.py | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 threefingerwindowmove@do.sch.dev.gmail.com/swipe3to4.py diff --git a/threefingerwindowmove@do.sch.dev.gmail.com/swipe3to4.py b/threefingerwindowmove@do.sch.dev.gmail.com/swipe3to4.py new file mode 100644 index 0000000..b2665fc --- /dev/null +++ b/threefingerwindowmove@do.sch.dev.gmail.com/swipe3to4.py @@ -0,0 +1,21 @@ +#reassign existing gnome gestures from 3 to 4 fingers +#run with sudo + +#from https://github.com/icedman/gnome-shell-hammer/blob/master/shell/swipe3to4.py + +f=open("/usr/lib/gnome-shell/libgnome-shell.so","rb") +s=f.read() +f.close() + +# gesture +s=s.replace(b'GESTURE_FINGER_COUNT\x20=\x203',b'GESTURE_FINGER_COUNT\x20=\x204') + +# radius .. 30px ick +s=s.replace(b'RADIUS_PIXELS\x20=\x2030',b'RADIUS_PIXELS\x20=\x2010') + +# overview startup animation +s=s.replace(b'Main.panel.style\x20=\x20\'tr',b'callback();\x20return;\x20//') + +f=open("libgnome-shell-replaced.so","wb") +f.write(s) +f.close()