1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
|
//////////////////////////////////////////////////////////////////////
// This file was auto-generated by codelite's wxCrafter Plugin
// wxCrafter project file: messagepane.wxcp
// Do not modify this file by hand!
//////////////////////////////////////////////////////////////////////
#include "messagepane_base.h"
// Declare the bitmap loading function
extern void wxC2A73InitBitmapResources();
static bool bBitmapLoaded = false;
MessagePaneBase::MessagePaneBase(wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style)
: wxPanel(parent, id, pos, size, style)
{
if ( !bBitmapLoaded ) {
// We need to initialise the default bitmap handler
wxXmlResource::Get()->AddHandler(new wxBitmapXmlHandler);
wxC2A73InitBitmapResources();
bBitmapLoaded = true;
}
wxBoxSizer* bSizer8 = new wxBoxSizer(wxVERTICAL);
this->SetSizer(bSizer8);
m_panel2 = new wxPanel(this, wxID_ANY, wxDefaultPosition, wxSize(-1, -1), wxTAB_TRAVERSAL|wxBORDER_SIMPLE);
m_panel2->SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOBK));
bSizer8->Add(m_panel2, 1, wxEXPAND, 0);
wxBoxSizer* mainSizer = new wxBoxSizer(wxHORIZONTAL);
m_panel2->SetSizer(mainSizer);
wxBoxSizer* bSizer81 = new wxBoxSizer(wxHORIZONTAL);
mainSizer->Add(bSizer81, 1, wxALIGN_CENTER_VERTICAL, 5);
wxBoxSizer* bSizer4 = new wxBoxSizer(wxHORIZONTAL);
bSizer81->Add(bSizer4, 1, wxEXPAND, 5);
m_bitmap1 = new wxStaticBitmap(m_panel2, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize(48,48), 0 );
bSizer4->Add(m_bitmap1, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5);
m_panel1 = new wxPanel(m_panel2, wxID_ANY, wxDefaultPosition, wxSize(-1,-1), wxWANTS_CHARS|wxTAB_TRAVERSAL);
m_panel1->SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOBK));
bSizer4->Add(m_panel1, 1, wxALL|wxEXPAND, 5);
wxBoxSizer* bSizer2 = new wxBoxSizer(wxHORIZONTAL);
m_panel1->SetSizer(bSizer2);
wxBoxSizer* bSizer3 = new wxBoxSizer(wxVERTICAL);
bSizer2->Add(bSizer3, 1, wxALIGN_CENTER_VERTICAL, 5);
m_staticText2 = new wxStaticText(m_panel1, wxID_ANY, _("Message:"), wxDefaultPosition, wxSize(-1, -1), 0);
m_staticText2->SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOBK));
m_staticText2->SetForegroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOTEXT));
bSizer3->Add(m_staticText2, 0, wxALL|wxEXPAND, 5);
m_staticTextMessage = new wxStaticText(m_panel1, wxID_ANY, wxT(""), wxDefaultPosition, wxSize(-1, -1), 0);
m_staticTextMessage->SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOBK));
m_staticTextMessage->SetForegroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOTEXT));
bSizer3->Add(m_staticTextMessage, 0, wxALL|wxEXPAND, 5);
m_DontAnnoyMeCheck = new wxCheckBox(m_panel1, wxID_ANY, _("Remember my answer and don't annoy me again!"), wxDefaultPosition, wxSize(-1, -1), 0);
m_DontAnnoyMeCheck->SetValue(false);
m_DontAnnoyMeCheck->SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOBK));
m_DontAnnoyMeCheck->SetForegroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOTEXT));
m_DontAnnoyMeCheck->SetToolTip(_("If you don't want to be spammed by this message again, tick the box. You can change your mind in Settings > Global Editor Preferences > Dialogs"));
bSizer3->Add(m_DontAnnoyMeCheck, 0, wxALL, 5);
wxBoxSizer* bSizer7 = new wxBoxSizer(wxVERTICAL);
bSizer4->Add(bSizer7, 0, wxALL, 5);
m_buttonClose = new wxButton(m_panel2, wxID_CANCEL, _("Hide"), wxDefaultPosition, wxSize(-1, -1), 0);
bSizer7->Add(m_buttonClose, 0, wxALL|wxEXPAND, 5);
m_buttonAction = new wxButton(m_panel2, wxID_ANY, wxT(""), wxDefaultPosition, wxSize(-1, -1), 0);
m_buttonAction->SetDefault();
bSizer7->Add(m_buttonAction, 0, wxALL|wxEXPAND, 5);
m_buttonAction1 = new wxButton(m_panel2, wxID_ANY, wxT(""), wxDefaultPosition, wxSize(-1, -1), 0);
bSizer7->Add(m_buttonAction1, 0, wxALL|wxEXPAND, 5);
m_buttonAction2 = new wxButton(m_panel2, wxID_ANY, wxT(""), wxDefaultPosition, wxSize(-1, -1), 0);
bSizer7->Add(m_buttonAction2, 0, wxALL|wxEXPAND, 5);
SetName(wxT("MessagePaneBase"));
SetSizeHints(-1,-1);
if ( GetSizer() ) {
GetSizer()->Fit(this);
}
CentreOnParent(wxBOTH);
// Connect events
this->Connect(wxEVT_ERASE_BACKGROUND, wxEraseEventHandler(MessagePaneBase::OnEraseBG), NULL, this);
this->Connect(wxEVT_PAINT, wxPaintEventHandler(MessagePaneBase::OnPaint), NULL, this);
m_buttonClose->Connect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(MessagePaneBase::OnButtonClose), NULL, this);
m_buttonAction->Connect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(MessagePaneBase::OnActionButton), NULL, this);
m_buttonAction1->Connect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(MessagePaneBase::OnActionButton1), NULL, this);
m_buttonAction2->Connect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(MessagePaneBase::OnActionButton2), NULL, this);
}
MessagePaneBase::~MessagePaneBase()
{
this->Disconnect(wxEVT_ERASE_BACKGROUND, wxEraseEventHandler(MessagePaneBase::OnEraseBG), NULL, this);
this->Disconnect(wxEVT_PAINT, wxPaintEventHandler(MessagePaneBase::OnPaint), NULL, this);
m_buttonClose->Disconnect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(MessagePaneBase::OnButtonClose), NULL, this);
m_buttonAction->Disconnect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(MessagePaneBase::OnActionButton), NULL, this);
m_buttonAction1->Disconnect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(MessagePaneBase::OnActionButton1), NULL, this);
m_buttonAction2->Disconnect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(MessagePaneBase::OnActionButton2), NULL, this);
}
|