From 524679ca67f977ebadb143205d5c45f798827e67 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 7 Dec 2012 01:46:36 +0300 Subject: Resize screen buttons with window resizing. --- src/touchmanager.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/touchmanager.h') diff --git a/src/touchmanager.h b/src/touchmanager.h index ec4c46bb3..f54520cf7 100644 --- a/src/touchmanager.h +++ b/src/touchmanager.h @@ -45,11 +45,12 @@ const int actionsSize = Input::KEY_TOTAL; struct TouchItem final { - TouchItem(const gcn::Rectangle rect0, ImageRect *const images0, + TouchItem(const gcn::Rectangle rect0, int type0, ImageRect *const images0, int x0, int y0, int width0, int height0, TouchFuncPtr ptrAll, TouchFuncPtr ptrPressed, TouchFuncPtr ptrReleased, TouchFuncPtr ptrOut) : rect(rect0), + type(type0), images(images0), x(x0), y(y0), @@ -65,6 +66,7 @@ struct TouchItem final A_DELETE_COPY(TouchItem) gcn::Rectangle rect; + int type; ImageRect *images; int x; int y; @@ -104,8 +106,6 @@ class TouchManager final void clear(); -// void unloadTouchItem(TouchItem **item0); - void draw(); bool processEvent(const MouseInput &mouseInput); @@ -118,6 +118,8 @@ class TouchManager final mActions[index] = value; } + void resize(int width, int height); + private: TouchItem *mKeyboard; TouchItem *mPad; -- cgit v1.2.3-60-g2f50