diff options
| author | rsn8887 | 2018-01-05 15:35:05 -0600 |
|---|---|---|
| committer | rsn8887 | 2018-01-05 15:51:39 -0600 |
| commit | e78984147d06dbbc1e1c373c90a8bdd02bc0d1e0 (patch) | |
| tree | 0c5ba99e1d6364531a53189dcd8a33090c67a795 /backends/platform/psp/cursor.cpp | |
| parent | b2cf5a30bfbb41500a9b81417614d6a9dbb50e6f (diff) | |
| download | scummvm-rg350-e78984147d06dbbc1e1c373c90a8bdd02bc0d1e0.tar.gz scummvm-rg350-e78984147d06dbbc1e1c373c90a8bdd02bc0d1e0.tar.bz2 scummvm-rg350-e78984147d06dbbc1e1c373c90a8bdd02bc0d1e0.zip | |
PSP: fix bit shifts of cursor x/y, fix too-slow cursor
Diffstat (limited to 'backends/platform/psp/cursor.cpp')
| -rw-r--r-- | backends/platform/psp/cursor.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/backends/platform/psp/cursor.cpp b/backends/platform/psp/cursor.cpp index 376e7eb3e5..b7c69d5b98 100644 --- a/backends/platform/psp/cursor.cpp +++ b/backends/platform/psp/cursor.cpp @@ -204,15 +204,15 @@ void Cursor::setLimits(uint32 width, uint32 height) { inline void Cursor::adjustXYForScreenSize(int32 &x, int32 &y) { DEBUG_ENTER_FUNC(); // We have our speed calibrated for the y axis at 480x272. The idea is to adjust this for other - // resolutions and for x, which is wider. + // resolutions int32 newX = x, newY = y; if (_mouseLimitWidth >= 600) { // multiply by 2 - newX <<= 1; - newY <<= 1; + newX *= 2; + newY *= 2; } else if (_mouseLimitWidth >= 480) { // multiply by 1.5 - newX = newX + (newX >> 1); - newY = newY + (newY >> 1); + newX = newX + (newX / 2); + newY = newY + (newY / 2); } } |
