Include missing JGE files from my last commit
This commit is contained in:
+2
-2
@@ -73,7 +73,7 @@ public:
|
|||||||
class JGuiController
|
class JGuiController
|
||||||
{
|
{
|
||||||
protected:
|
protected:
|
||||||
static JGE* mEngine;
|
JGE* mEngine;
|
||||||
|
|
||||||
int mId;
|
int mId;
|
||||||
bool mActive;
|
bool mActive;
|
||||||
@@ -101,7 +101,7 @@ public:
|
|||||||
vector<JGuiObject*> mObjects;
|
vector<JGuiObject*> mObjects;
|
||||||
int mCount;
|
int mCount;
|
||||||
|
|
||||||
JGuiController(int id, JGuiListener* listener);
|
JGuiController(JGE* jge, int id, JGuiListener* listener);
|
||||||
~JGuiController();
|
~JGuiController();
|
||||||
|
|
||||||
virtual void Render();
|
virtual void Render();
|
||||||
|
|||||||
+7
-7
@@ -13,8 +13,6 @@
|
|||||||
|
|
||||||
JGE* JGuiObject::mEngine = NULL;
|
JGE* JGuiObject::mEngine = NULL;
|
||||||
|
|
||||||
JGE* JGuiController::mEngine = NULL;
|
|
||||||
|
|
||||||
JGuiObject::JGuiObject(int id) :
|
JGuiObject::JGuiObject(int id) :
|
||||||
mId(id)
|
mId(id)
|
||||||
{
|
{
|
||||||
@@ -55,11 +53,9 @@ ostream& operator<<(ostream &out, const JGuiObject &j)
|
|||||||
return j.toString(out);
|
return j.toString(out);
|
||||||
}
|
}
|
||||||
|
|
||||||
JGuiController::JGuiController(int id, JGuiListener* listener) :
|
JGuiController::JGuiController(JGE* jge, int id, JGuiListener* listener) :
|
||||||
mId(id), mListener(listener)
|
mEngine(jge), mId(id), mListener(listener)
|
||||||
{
|
{
|
||||||
mEngine = JGE::GetInstance();
|
|
||||||
|
|
||||||
mBg = NULL;
|
mBg = NULL;
|
||||||
mShadingBg = NULL;
|
mShadingBg = NULL;
|
||||||
|
|
||||||
@@ -189,11 +185,15 @@ bool JGuiController::CheckUserInput(JButton key)
|
|||||||
void JGuiController::Update(float dt)
|
void JGuiController::Update(float dt)
|
||||||
{
|
{
|
||||||
for (int i = 0; i < mCount; i++)
|
for (int i = 0; i < mCount; i++)
|
||||||
if (mObjects[i] != NULL) mObjects[i]->Update(dt);
|
if (mObjects[i] != NULL)
|
||||||
|
mObjects[i]->Update(dt);
|
||||||
|
|
||||||
|
if(mEngine)
|
||||||
|
{
|
||||||
JButton key = mEngine->ReadButton();
|
JButton key = mEngine->ReadButton();
|
||||||
CheckUserInput(key);
|
CheckUserInput(key);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void JGuiController::Add(JGuiObject* ctrl)
|
void JGuiController::Add(JGuiObject* ctrl)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user