aboutsummaryrefslogtreecommitdiff
path: root/engines/mohawk/cursors.h
diff options
context:
space:
mode:
authorBastien Bouclet2017-07-01 14:56:03 +0200
committerEugene Sandulenko2017-07-03 08:50:10 +0200
commitb9a72ff7a6dc7033beae4a75dc5f596264c39419 (patch)
treeb2956cb326808f0254df92ec9cc49d126db2fe78 /engines/mohawk/cursors.h
parent672cfbd518626fffc3476c2f6d0cdd391ab12e17 (diff)
downloadscummvm-rg350-b9a72ff7a6dc7033beae4a75dc5f596264c39419.tar.gz
scummvm-rg350-b9a72ff7a6dc7033beae4a75dc5f596264c39419.tar.bz2
scummvm-rg350-b9a72ff7a6dc7033beae4a75dc5f596264c39419.zip
MOHAWK: Preload all the PE cursors on startup
We were previously reloading the current cursor from raw data on each frame.
Diffstat (limited to 'engines/mohawk/cursors.h')
-rw-r--r--engines/mohawk/cursors.h14
1 files changed, 11 insertions, 3 deletions
diff --git a/engines/mohawk/cursors.h b/engines/mohawk/cursors.h
index 742ae30107..d0d38c9b46 100644
--- a/engines/mohawk/cursors.h
+++ b/engines/mohawk/cursors.h
@@ -28,11 +28,14 @@
namespace Common {
class MacResManager;
class NEResources;
-class PEResources;
class SeekableReadStream;
class String;
}
+namespace Graphics {
+struct WinCursorGroup;
+}
+
#include "mohawk/resource.h"
namespace Mohawk {
@@ -170,10 +173,15 @@ public:
~PECursorManager();
void setCursor(uint16 id);
- bool hasSource() const { return _exe != 0; }
+ bool hasSource() const { return !_cursors.empty(); }
private:
- Common::PEResources *_exe;
+ struct CursorItem {
+ uint16 id;
+ Graphics::WinCursorGroup *cursorGroup;
+ };
+
+ Common::Array<CursorItem> _cursors;
};
} // End of namespace Mohawk