Merge pull request #935 from alebastr/ignore-emulated-scroll-events

fix(sway/workspaces): ignore emulated scroll events
This commit is contained in:
Alex 2020-12-05 21:02:24 +01:00 committed by GitHub
commit f91dc7fb6e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -291,6 +291,12 @@ std::string Workspaces::getIcon(const std::string &name, const Json::Value &node
}
bool Workspaces::handleScroll(GdkEventScroll *e) {
if (gdk_event_get_pointer_emulated((GdkEvent *)e)) {
/**
* Ignore emulated scroll events on window
*/
return false;
}
auto dir = AModule::getScrollDir(e);
if (dir == SCROLL_DIR::NONE) {
return true;