'Edit' and 'gallery' button for symbol editor

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@522 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-07-07 18:04:02 +00:00
parent a3b2403858
commit d4e46e06d8
6 changed files with 103 additions and 11 deletions
+12
View File
@@ -20,8 +20,20 @@ class SymbolValueEditor : public SymbolValueViewer, public ValueEditor {
public:
DECLARE_VALUE_EDITOR(Symbol);
virtual void draw(RotatedDC& dc);
virtual bool onLeftDown (const RealPoint& pos, wxMouseEvent&);
virtual bool onLeftUp (const RealPoint& pos, wxMouseEvent&);
virtual bool onLeftDClick(const RealPoint& pos, wxMouseEvent&);
virtual bool onMotion (const RealPoint& pos, wxMouseEvent&);
virtual void determineSize(bool);
private:
/// Draw a button, buttons are numbered from the right
void drawButton(RotatedDC& dc, int button, const String& text);
/// Is there a button at the given position? returns the button index, or -1 if there is no button
int findButton(const RealPoint& pos);
// button, or -1 for mouse down, but not on button, or -2 for mouse not down
int button_down;
};
// ----------------------------------------------------------------------------- : EOF