RCS file: /cvsroot/scummvm/scummvm/backends/sdl/graphics.cpp,v
retrieving revision 1.49
diff -u -r1.49 graphics.cpp
|
|
|
|
| 1430 | 1430 | } |
| 1431 | 1431 | |
| 1432 | 1432 | void OSystem_SDL::undrawMouse() { |
| | 1433 | const int x = _mouseBackup.x; |
| | 1434 | const int y = _adjustAspectRatio ? aspect2Real(_mouseBackup.y) : _mouseBackup.y; |
| | 1435 | |
| 1433 | 1436 | // When we switch bigger overlay off mouse jumps. Argh! |
| 1434 | | // this intended to prevent undrawing offscreen mouse |
| 1435 | | if (!_overlayVisible) { |
| 1436 | | if (_adjustAspectRatio) { |
| 1437 | | if (_mouseBackup.x > _screenWidth || aspect2Real(_mouseBackup.y) > _screenHeight) |
| 1438 | | return; |
| 1439 | | } else { |
| 1440 | | if (_mouseBackup.x > _screenWidth || _mouseBackup.y > _screenHeight) |
| 1441 | | return; |
| 1442 | | } |
| | 1437 | // This is intended to prevent undrawing offscreen mouse |
| | 1438 | if (!_overlayVisible && (x >= _screenWidth || y >= _screenHeight)) { |
| | 1439 | return; |
| 1443 | 1440 | } |
| 1444 | | |
| 1445 | | if (_mouseBackup.w) { |
| 1446 | | if (_adjustAspectRatio) |
| 1447 | | addDirtyRect(_mouseBackup.x, aspect2Real(_mouseBackup.y), _mouseBackup.w, |
| 1448 | | _mouseBackup.h); |
| 1449 | | else |
| 1450 | | addDirtyRect(_mouseBackup.x, _mouseBackup.y, _mouseBackup.w, |
| 1451 | | _mouseBackup.h); |
| | 1441 | |
| | 1442 | if (_mouseBackup.w != 0 && _mouseBackup.h != 0) { |
| | 1443 | addDirtyRect(x, y, _mouseBackup.w, _mouseBackup.h); |
| 1452 | 1444 | } |
| 1453 | 1445 | } |
| 1454 | 1446 | |