mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-16 00:12:51 +00:00
(svn r18933) -Codechange: Don't constantly redraw a window when moving it unless it actually moves.
This commit is contained in:
parent
07b285c5ca
commit
08a24fcc31
@ -1513,6 +1513,9 @@ static bool HandleWindowDragging()
|
||||
/* Get out immediately if no window is being dragged at all. */
|
||||
if (!_dragging_window) return true;
|
||||
|
||||
/* If button still down, but cursor hasn't moved, there is nothing to do. */
|
||||
if (_left_button_down && _cursor.delta.x == 0 && _cursor.delta.y == 0) return false;
|
||||
|
||||
/* Otherwise find the window... */
|
||||
Window *w;
|
||||
FOR_ALL_WINDOWS_FROM_BACK(w) {
|
||||
|
Loading…
Reference in New Issue
Block a user