* New menu style - step one.
  More improvements are to come, but this should be stable and have a good
  portion of what is to be done.
This commit is contained in:
jean.chalard
2008-12-30 05:24:38 +00:00
parent 3e9ff2b580
commit a82d4b51bb
19 changed files with 367 additions and 192 deletions

View File

@@ -5,6 +5,7 @@
#include <JLBFont.h>
#include <JGui.h>
#include <string>
#include "SimpleMenu.h"
using std::string;
@@ -16,18 +17,20 @@ class SimpleMenuItem: public JGuiObject
{
private:
bool mHasFocus;
SimpleMenu* parent;
JLBFont *mFont;
string mText;
int mX;
int mY;
float mScale;
float mTargetScale;
public:
SimpleMenuItem(int id, JLBFont *font, const char* text, int x, int y, bool hasFocus = false);
SimpleMenuItem(SimpleMenu* _parent, int id, JLBFont *font, const char* text, int x, int y, bool hasFocus = false);
int mX;
int mY;
void Relocate(int x, int y);
int GetWidth();
void RenderWithOffset(float yOffset);
virtual void Render();
@@ -39,4 +42,3 @@ class SimpleMenuItem: public JGuiObject
};
#endif