mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-17 11:24:27 +01:00
Could scroll outside the list area
This commit is contained in:
1 parent
e3335b5817
commit
78239e7796
1 file changed
+2
-1
@@ -341,10 +341,11 @@ int UIList::Do(int id, int x, int y, int w, int h, UIListAdapter *adapter) {
|
||||
if (inertiaY > 20) inertiaY = 20;
|
||||
if (inertiaY < -20) inertiaY = -20;
|
||||
|
||||
float mouseY = uistate.mousey[0];
|
||||
if (!uistate.mousedown[0]) {
|
||||
// Let it slide if the pointer is not down
|
||||
scrollY += inertiaY;
|
||||
} else if (scrolling) {
|
||||
} else if (scrolling && mouseY > y && mouseY < y + h) {
|
||||
// Pointer is down so stick to it
|
||||
scrollY = startScrollY - (uistate.mousey[0] - startDragY);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user