mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
Workspaces: fix twitchy scrolling on touchpads
Previously, any and all scroll events were interpreted as reason to switch workspaces. This resulted in twitchy behaviour, where the scrolling was practically unusable. Now, we pool all scroll values, and only scroll if the value is larger than the new config option "smooth-scrolling-threshold". If this option is not set, the behaviour is unchanged.
This commit is contained in:
@ -41,6 +41,7 @@ class Workspaces : public IModule, public sigc::trackable {
|
||||
util::JsonParser parser_;
|
||||
bool scrolling_;
|
||||
std::unordered_map<std::string, Gtk::Button> buttons_;
|
||||
gdouble distance_scrolled_;
|
||||
|
||||
util::SleeperThread thread_;
|
||||
Ipc ipc_;
|
||||
|
Reference in New Issue
Block a user