summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorQue Quotion2018-09-18 17:48:36 +0900
committerQue Quotion2018-09-18 17:48:36 +0900
commitbc99640a581234f74a6f6c8d7aaa7be098b18fb1 (patch)
treed4e4ff5a50044dcb85fa5f8d7491a74d2eefb6d3
parentc98ac939282f17c07588c6c7465db1c127deacf3 (diff)
downloadaur-bc99640a581234f74a6f6c8d7aaa7be098b18fb1.tar.gz
Stabilize Dodge(-Float) mouseover behavior; streamline show/hide routines; minor refactoring
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD2
-rw-r--r--autohide.patch72
3 files changed, 39 insertions, 37 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 93fec63398f5..773134be18f5 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -52,7 +52,7 @@ pkgbase = wingpanel-standalone-git
sha256sums = 7f972d79b4d72f7b274a96e1a5150cba0e3869ad85215ae01ad2bc19802cdbb9
sha256sums = 20ec1d51a6610bf0105c772e4d1d4ac8f35ea0ee33b066981db57dc19fe3bdc6
sha256sums = b1902c1d44ac546df63cd0224a7d2ef2cb6394ca556512c30c370d387db7bbab
- sha256sums = 1ee7757d67eb0fb3f67a036152c599390383985bc2d1b573b605c3eed437a02e
+ sha256sums = 259ff69bd7be5b0a3d8fe437f9313b7dda2636286ce8828e0d2ea51081bbf6ea
sha256sums = 53bfa2220d14065ca848c36217abe812685c7d6e0d42251423d0faa2a0ac5394
pkgname = wingpanel-standalone-git
diff --git a/PKGBUILD b/PKGBUILD
index 53b70d36a57d..bfe95a26176d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -34,7 +34,7 @@ sha256sums=('SKIP'
'7f972d79b4d72f7b274a96e1a5150cba0e3869ad85215ae01ad2bc19802cdbb9'
'20ec1d51a6610bf0105c772e4d1d4ac8f35ea0ee33b066981db57dc19fe3bdc6'
'b1902c1d44ac546df63cd0224a7d2ef2cb6394ca556512c30c370d387db7bbab'
- '1ee7757d67eb0fb3f67a036152c599390383985bc2d1b573b605c3eed437a02e'
+ '259ff69bd7be5b0a3d8fe437f9313b7dda2636286ce8828e0d2ea51081bbf6ea'
'53bfa2220d14065ca848c36217abe812685c7d6e0d42251423d0faa2a0ac5394')
pkgver() {
diff --git a/autohide.patch b/autohide.patch
index c4f11d0af7fe..489e6e9427e0 100644
--- a/autohide.patch
+++ b/autohide.patch
@@ -98,7 +98,7 @@ index c48b5ea..81ec2f2 100644
return true;
}
-@@ -91,7 +115,174 @@ public class Wingpanel.PanelWindow : Gtk.Window {
+@@ -91,7 +115,176 @@ public class Wingpanel.PanelWindow : Gtk.Window {
Services.BackgroundManager.initialize (this.monitor_number, panel_height);
@@ -138,8 +138,14 @@ index c48b5ea..81ec2f2 100644
+ private void update_visibility_active_change (Wnck.Window? active_window) {
+ if (should_hide_active_change (active_window)) {
+ hide_panel ();
++ this.enter_notify_event.connect (show_panel);
++ this.motion_notify_event.connect (show_panel);
++ this.leave_notify_event.connect (hide_panel);
+ } else {
+ show_panel ();
++ this.enter_notify_event.disconnect (show_panel);
++ this.motion_notify_event.disconnect (show_panel);
++ this.leave_notify_event.disconnect (hide_panel);
+ }
+ }
+
@@ -205,16 +211,9 @@ index c48b5ea..81ec2f2 100644
+ if (timeout > 0) {
+ Source.remove (timeout);
+ }
-+ if (autohide == "Dodge" || autohide == "Dodge-Float") {
-+ if (!should_hide_active_change (wnck_screen.get_active_window())) {
-+ return true;
-+ }
-+ }
-+ if (popover_manager.current_indicator == null) {
-+ Thread.usleep (autohide_delay * 1000);
-+ }
-+ strut = true;
+ hiding = true;
++ strut = true;
++ Thread.usleep (autohide_delay * 1000);
+ timeout = Timeout.add (100 / panel_height, animation_step);
+ return true;
+ }
@@ -223,52 +222,55 @@ index c48b5ea..81ec2f2 100644
+ if (timeout > 0) {
+ Source.remove (timeout);
+ }
-+ if (popover_manager.current_indicator == null && autohide != "Disabled") {
-+ Thread.usleep (autohide_delay * 1000);
-+ }
-+ if (autohide == "Dodge-Float" || autohide == "Float") {
-+ strut = false;
-+ } else {
-+ strut = true;
-+ }
+ hiding = false;
-+ if (autohide == "Disabled") {
-+ timeout = Timeout.add (300 / panel_height, animation_step);
-+ } else {
-+ timeout = Timeout.add (100 / panel_height, animation_step);
++ switch (autohide) {
++ case "Autohide":
++ case "Dodge":
++ strut = true;
++ Thread.usleep (autohide_delay * 1000);
++ timeout = Timeout.add (100 / panel_height, animation_step);
++ break;
++ case "Float":
++ case "Dodge-Float":
++ strut = false;
++ Thread.usleep (autohide_delay * 1000);
++ timeout = Timeout.add (100 / panel_height, animation_step);
++ break;
++ default:
++ strut = true;
++ timeout = Timeout.add (300 / panel_height, animation_step);
++ break;
+ }
+ return true;
+ }
+
+ private void update_autohide_mode () {
+ switch (autohide) {
-+ case "Disabled":
-+ this.enter_notify_event.disconnect (show_panel);
-+ this.motion_notify_event.disconnect (show_panel);
-+ this.leave_notify_event.disconnect (hide_panel);
++ case "Autohide":
++ case "Float":
++ hide_panel ();
++ this.enter_notify_event.connect (show_panel);
++ this.motion_notify_event.connect (show_panel);
++ this.leave_notify_event.connect (hide_panel);
+ wnck_screen.active_window_changed.disconnect (active_window_changed);
+ wnck_screen.active_workspace_changed.disconnect (active_workspace_changed);
+ wnck_screen.viewports_changed.disconnect (viewports_changed);
-+ show_panel ();
+ break;
+ case "Dodge":
+ case "Dodge-Float":
-+ this.enter_notify_event.connect (show_panel);
-+ this.motion_notify_event.connect (show_panel);
-+ this.leave_notify_event.connect (hide_panel);
++ show_panel ();
+ wnck_screen.active_window_changed.connect (active_window_changed);
+ wnck_screen.active_workspace_changed.connect (active_workspace_changed);
+ wnck_screen.viewports_changed.connect (viewports_changed);
-+ show_panel ();
+ break;
+ default:
-+ this.enter_notify_event.connect (show_panel);
-+ this.motion_notify_event.connect (show_panel);
-+ this.leave_notify_event.connect (hide_panel);
++ show_panel ();
++ this.enter_notify_event.disconnect (show_panel);
++ this.motion_notify_event.disconnect (show_panel);
++ this.leave_notify_event.disconnect (hide_panel);
+ wnck_screen.active_window_changed.disconnect (active_window_changed);
+ wnck_screen.active_workspace_changed.disconnect (active_workspace_changed);
+ wnck_screen.viewports_changed.disconnect (viewports_changed);
-+ hide_panel ();
+ break;
+ }
}