mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-21 13:28:05 +01:00
Fixed scrolling directions for mice wheels.
This commit is contained in:
@@ -1313,7 +1313,8 @@ scrollersCallBack(WMWidget *w, void *self)
|
|||||||
if (tPtr->vpos>16) tPtr->vpos-=16;
|
if (tPtr->vpos>16) tPtr->vpos-=16;
|
||||||
else tPtr->vpos=0;
|
else tPtr->vpos=0;
|
||||||
scroll=True;
|
scroll=True;
|
||||||
}break;
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
case WSIncrementLine: {
|
case WSIncrementLine: {
|
||||||
int limit = tPtr->docHeight - height;
|
int limit = tPtr->docHeight - height;
|
||||||
@@ -1321,7 +1322,9 @@ scrollersCallBack(WMWidget *w, void *self)
|
|||||||
if (tPtr->vpos<limit-16) tPtr->vpos+=16;
|
if (tPtr->vpos<limit-16) tPtr->vpos+=16;
|
||||||
else tPtr->vpos=limit;
|
else tPtr->vpos=limit;
|
||||||
scroll = True;
|
scroll = True;
|
||||||
}}break;
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
case WSDecrementPage:
|
case WSDecrementPage:
|
||||||
if(((int)tPtr->vpos - (int)height) >= 0)
|
if(((int)tPtr->vpos - (int)height) >= 0)
|
||||||
@@ -2405,13 +2408,13 @@ handleActionEvents(XEvent *event, void *data)
|
|||||||
|
|
||||||
if (event->xbutton.button
|
if (event->xbutton.button
|
||||||
== WINGsConfiguration.mouseWheelDown) {
|
== WINGsConfiguration.mouseWheelDown) {
|
||||||
WMScrollText(tPtr, -16);
|
WMScrollText(tPtr, 16);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (event->xbutton.button
|
if (event->xbutton.button
|
||||||
== WINGsConfiguration.mouseWheelUp) {
|
== WINGsConfiguration.mouseWheelUp) {
|
||||||
WMScrollText(tPtr, 16);
|
WMScrollText(tPtr, -16);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user