diff options
author | Strangerke | 2015-11-29 18:10:06 +0100 |
---|---|---|
committer | Willem Jan Palenstijn | 2015-12-23 21:33:43 +0100 |
commit | d96484d81c2645b7b714845a9176ba264f52bbc0 (patch) | |
tree | 474802cf43f2eecfc69ad3637fa0851ec6030546 /engines/lab/mouse.h | |
parent | 8d70f33efe09b01f6f3d48c83f7fbc5c6835d50e (diff) | |
download | scummvm-rg350-d96484d81c2645b7b714845a9176ba264f52bbc0.tar.gz scummvm-rg350-d96484d81c2645b7b714845a9176ba264f52bbc0.tar.bz2 scummvm-rg350-d96484d81c2645b7b714845a9176ba264f52bbc0.zip |
LAB: Move mouse code in separate class, move some functions to LabEngine. (WIP)
Diffstat (limited to 'engines/lab/mouse.h')
-rw-r--r-- | engines/lab/mouse.h | 40 |
1 files changed, 21 insertions, 19 deletions
diff --git a/engines/lab/mouse.h b/engines/lab/mouse.h index 489bb1e989..6468ba91c7 100644 --- a/engines/lab/mouse.h +++ b/engines/lab/mouse.h @@ -38,25 +38,27 @@ namespace Lab { struct Gadget; -void initMouse(); - -void updateMouse(); - -void mouseShow(); - -void mouseHide(); - -Common::Point getMousePos(); - -void setMousePos(Common::Point pos); - -bool mouseButton(uint16 *x, uint16 *y, bool leftbutton); - -Gadget *mouseGadget(); - -void attachGadgetList(Gadget *GadList); - -void mouseHandler(int flag, Common::Point pos); +class LabEngine; + +class EventManager { +private: + LabEngine *_vm; + +public: + EventManager (LabEngine *vm); + + Gadget *checkGadgetHit(Gadget *gadlist, Common::Point pos); + void initMouse(); + void updateMouse(); + void mouseShow(); + void mouseHide(); + Common::Point getMousePos(); + void setMousePos(Common::Point pos); + bool mouseButton(uint16 *x, uint16 *y, bool leftbutton); + Gadget *mouseGadget(); + void attachGadgetList(Gadget *GadList); + void mouseHandler(int flag, Common::Point pos); +}; } // End of namespace Lab |