mirror of
https://github.com/X11Libre/xf86-input-synaptics.git
synced 2026-04-14 11:54:16 +00:00
Made it possible to have both circular scrolling and
vertical/horizontal scrolling enabled at the same time. From Matthias Ihmig <m.ihmig@gmx.net>.
This commit is contained in:
5
README
5
README
@@ -166,7 +166,10 @@ corner. Once scrolling is engaged, moving your finger in clockwise
|
||||
circles around the trackpad will generate scroll down events and
|
||||
counter clockwise scroll up events. Lifting your finger will disengage
|
||||
circular scrolling. Use tight circles near the center of the pad for
|
||||
fast scrolling and large circles for better control.
|
||||
fast scrolling and large circles for better control. When used
|
||||
together with vertical scrolling, hitting the upper or lower right
|
||||
corner will seamlessly switch over from vertical to circular
|
||||
scrolling.
|
||||
|
||||
|
||||
FAQ
|
||||
|
||||
15
synaptics.c
15
synaptics.c
@@ -1063,7 +1063,8 @@ HandleState(LocalDevicePtr local, struct SynapticsHwState* hw)
|
||||
priv->scroll_a = angle(priv, hw->x, hw->y);
|
||||
DBG(7, ErrorF("circular scroll detected on edge\n"));
|
||||
}
|
||||
} else {
|
||||
}
|
||||
if (!priv->circ_scroll_on) {
|
||||
if ((para->scroll_dist_vert != 0) && (edge & RIGHT_EDGE)) {
|
||||
priv->vert_scroll_on = TRUE;
|
||||
priv->scroll_y = hw->y;
|
||||
@@ -1091,6 +1092,18 @@ HandleState(LocalDevicePtr local, struct SynapticsHwState* hw)
|
||||
}
|
||||
|
||||
/* scroll processing */
|
||||
|
||||
/* if hitting a corner (top right or bottom right) while vertical scrolling is active,
|
||||
switch over to circular scrolling smoothly */
|
||||
if (priv->vert_scroll_on && !priv->horiz_scroll_on && para->circular_scrolling) {
|
||||
if ((edge & RIGHT_EDGE) && (edge & (TOP_EDGE | BOTTOM_EDGE))) {
|
||||
priv->vert_scroll_on = FALSE;
|
||||
priv->circ_scroll_on = TRUE;
|
||||
priv->scroll_a = angle(priv, hw->x, hw->y);
|
||||
DBG(7, ErrorF("switching to circular scrolling\n"));
|
||||
}
|
||||
}
|
||||
|
||||
scroll_up = 0;
|
||||
scroll_down = 0;
|
||||
if (priv->vert_scroll_on) {
|
||||
|
||||
Reference in New Issue
Block a user