diff options
author | Thales1330 <thaleslima.ufu@gmail.com> | 2017-01-20 13:34:14 -0200 |
---|---|---|
committer | Thales1330 <thaleslima.ufu@gmail.com> | 2017-01-20 13:34:14 -0200 |
commit | 6f7aebd00330c40007b41aa6e48847695924fe29 (patch) | |
tree | 38dd92c3c26864eea6844a86683a413941525ebf /Project/ControlEditor.h | |
parent | 864842440bb7fd9f8495314b8bfa2e2c8a0d47f4 (diff) | |
download | PSP.git-6f7aebd00330c40007b41aa6e48847695924fe29.tar.gz PSP.git-6f7aebd00330c40007b41aa6e48847695924fe29.tar.xz PSP.git-6f7aebd00330c40007b41aa6e48847695924fe29.zip |
ControlButton fixed
Diffstat (limited to 'Project/ControlEditor.h')
-rw-r--r-- | Project/ControlEditor.h | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/Project/ControlEditor.h b/Project/ControlEditor.h index fd35452..95edc07 100644 --- a/Project/ControlEditor.h +++ b/Project/ControlEditor.h @@ -3,8 +3,8 @@ #include "ControlEditorBase.h" #include <wx/wrapsizer.h> -#include <wx/bmpbuttn.h> #include <wx/dcclient.h> +#include <wx/dcscreen.h> #include <wx/graphics.h> class ControlElementButton : public wxWindow @@ -14,10 +14,25 @@ public: ~ControlElementButton(); protected: - void OnPaint(wxPaintEvent& event); - + virtual void OnPaint(wxPaintEvent& event); + virtual void OnMouseEnter(wxMouseEvent& event); + virtual void OnMouseLeave(wxMouseEvent& event); + virtual void OnLeftClickDown(wxMouseEvent& event); + virtual void OnLeftClickUp(wxMouseEvent& event); + wxString m_label; + wxFont m_font; + wxPoint m_labelPosition; + wxImage m_image; + wxSize m_imageSize; + wxPoint m_imagePosition; + + int m_borderSize = 2; + bool m_mouseAbove = false; + bool m_selected = false; + + wxSize m_buttonSize; }; class ControlEditor : public ControlEditorBase |