summaryrefslogtreecommitdiffstats
path: root/gui/objects.hpp
diff options
context:
space:
mode:
authorAleksa Sarai <cyphar@cyphar.com>2015-12-31 17:36:00 +0100
committerz31s1g <z31s1g@googlemail.com>2016-01-02 19:44:48 +0100
commitb25a18395e666bbe13506651d5de84054aae0fcc (patch)
tree2fd5195a8b25ac31b614cea56c67499866434bcd /gui/objects.hpp
parenttwrp: fix a typo and remove whitespace (diff)
downloadandroid_bootable_recovery-b25a18395e666bbe13506651d5de84054aae0fcc.tar
android_bootable_recovery-b25a18395e666bbe13506651d5de84054aae0fcc.tar.gz
android_bootable_recovery-b25a18395e666bbe13506651d5de84054aae0fcc.tar.bz2
android_bootable_recovery-b25a18395e666bbe13506651d5de84054aae0fcc.tar.lz
android_bootable_recovery-b25a18395e666bbe13506651d5de84054aae0fcc.tar.xz
android_bootable_recovery-b25a18395e666bbe13506651d5de84054aae0fcc.tar.zst
android_bootable_recovery-b25a18395e666bbe13506651d5de84054aae0fcc.zip
Diffstat (limited to 'gui/objects.hpp')
-rw-r--r--gui/objects.hpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/gui/objects.hpp b/gui/objects.hpp
index ebf08a8db..4e7ea29f4 100644
--- a/gui/objects.hpp
+++ b/gui/objects.hpp
@@ -1134,6 +1134,7 @@ public:
virtual int Render(void);
virtual int Update(void);
virtual int NotifyTouch(TOUCH_STATE state, int x, int y);
+ virtual int NotifyVarChange(const std::string& varName, const std::string& value);
virtual int SetRenderPos(int x, int y, int w = 0, int h = 0);
protected:
@@ -1141,9 +1142,10 @@ protected:
void ResetActiveDots();
void ConnectDot(int dot_idx);
void ConnectIntermediateDots(int dot_idx);
+ void Resize(size_t size);
int InDot(int x, int y);
bool DotUsed(int dot_idx);
- static bool IsInRect(int x, int y, int rx, int ry, int rw, int rh);
+ std::string GeneratePassphrase();
void PatternDrawn();
struct Dot {
@@ -1152,8 +1154,11 @@ protected:
bool active;
};
- Dot mDots[9];
- int mConnectedDots[9];
+ std::string mSizeVar;
+ size_t mGridSize;
+
+ Dot* mDots;
+ int* mConnectedDots;
size_t mConnectedDotsLen;
int mCurLineX;
int mCurLineY;