mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-15 16:58:01 +00:00
SHERLOCK: Simplify Events not to need it's own copy of the mouse pos
This commit is contained in:
parent
34227d1b54
commit
437bcf3cfe
@ -154,9 +154,6 @@ void Events::pollEvents() {
|
||||
case Common::EVENT_RBUTTONUP:
|
||||
_mouseButtons &= ~2;
|
||||
return;
|
||||
case Common::EVENT_MOUSEMOVE:
|
||||
_mousePos = event.mouse;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@ -194,6 +191,13 @@ bool Events::checkForNextFrameCounter() {
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the current mouse position
|
||||
*/
|
||||
Common::Point Events::mousePos() const {
|
||||
return g_system->getEventManager()->getMousePos();
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a pending keypress
|
||||
*/
|
||||
|
@ -42,7 +42,6 @@ private:
|
||||
SherlockEngine *_vm;
|
||||
uint32 _frameCounter;
|
||||
uint32 _priorFrameTime;
|
||||
Common::Point _mousePos;
|
||||
ImageFile *_cursorImages;
|
||||
int _mouseButtons;
|
||||
|
||||
@ -79,7 +78,7 @@ public:
|
||||
|
||||
void pollEventsAndWait();
|
||||
|
||||
Common::Point mousePos() const { return _mousePos; }
|
||||
Common::Point mousePos() const;
|
||||
|
||||
uint32 getFrameCounter() const { return _frameCounter; }
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user