fixed the menu bug introduced by the previous commit
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14768 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -62,7 +62,7 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
// common part of all ctors
|
// common part of all ctors
|
||||||
void Init();
|
void Init(const wxString& text);
|
||||||
|
|
||||||
// DoSetText() transforms the accel mnemonics in our label from MSW/wxWin
|
// DoSetText() transforms the accel mnemonics in our label from MSW/wxWin
|
||||||
// style to GTK+ and is called from ctor and SetText()
|
// style to GTK+ and is called from ctor and SetText()
|
||||||
|
@@ -62,7 +62,7 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
// common part of all ctors
|
// common part of all ctors
|
||||||
void Init();
|
void Init(const wxString& text);
|
||||||
|
|
||||||
// DoSetText() transforms the accel mnemonics in our label from MSW/wxWin
|
// DoSetText() transforms the accel mnemonics in our label from MSW/wxWin
|
||||||
// style to GTK+ and is called from ctor and SetText()
|
// style to GTK+ and is called from ctor and SetText()
|
||||||
|
@@ -713,7 +713,7 @@ wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
|||||||
wxMenu *subMenu)
|
wxMenu *subMenu)
|
||||||
: wxMenuItemBase(parentMenu, id, text, help, kind, subMenu)
|
: wxMenuItemBase(parentMenu, id, text, help, kind, subMenu)
|
||||||
{
|
{
|
||||||
Init();
|
Init(text);
|
||||||
}
|
}
|
||||||
|
|
||||||
wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
||||||
@@ -725,15 +725,15 @@ wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
|||||||
: wxMenuItemBase(parentMenu, id, text, help,
|
: wxMenuItemBase(parentMenu, id, text, help,
|
||||||
isCheckable ? wxITEM_CHECK : wxITEM_NORMAL, subMenu)
|
isCheckable ? wxITEM_CHECK : wxITEM_NORMAL, subMenu)
|
||||||
{
|
{
|
||||||
Init();
|
Init(text);
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxMenuItem::Init()
|
void wxMenuItem::Init(const wxString& text)
|
||||||
{
|
{
|
||||||
m_labelWidget = (GtkWidget *) NULL;
|
m_labelWidget = (GtkWidget *) NULL;
|
||||||
m_menuItem = (GtkWidget *) NULL;
|
m_menuItem = (GtkWidget *) NULL;
|
||||||
|
|
||||||
DoSetText(m_text);
|
DoSetText(text);
|
||||||
}
|
}
|
||||||
|
|
||||||
wxMenuItem::~wxMenuItem()
|
wxMenuItem::~wxMenuItem()
|
||||||
|
@@ -713,7 +713,7 @@ wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
|||||||
wxMenu *subMenu)
|
wxMenu *subMenu)
|
||||||
: wxMenuItemBase(parentMenu, id, text, help, kind, subMenu)
|
: wxMenuItemBase(parentMenu, id, text, help, kind, subMenu)
|
||||||
{
|
{
|
||||||
Init();
|
Init(text);
|
||||||
}
|
}
|
||||||
|
|
||||||
wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
||||||
@@ -725,15 +725,15 @@ wxMenuItem::wxMenuItem(wxMenu *parentMenu,
|
|||||||
: wxMenuItemBase(parentMenu, id, text, help,
|
: wxMenuItemBase(parentMenu, id, text, help,
|
||||||
isCheckable ? wxITEM_CHECK : wxITEM_NORMAL, subMenu)
|
isCheckable ? wxITEM_CHECK : wxITEM_NORMAL, subMenu)
|
||||||
{
|
{
|
||||||
Init();
|
Init(text);
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxMenuItem::Init()
|
void wxMenuItem::Init(const wxString& text)
|
||||||
{
|
{
|
||||||
m_labelWidget = (GtkWidget *) NULL;
|
m_labelWidget = (GtkWidget *) NULL;
|
||||||
m_menuItem = (GtkWidget *) NULL;
|
m_menuItem = (GtkWidget *) NULL;
|
||||||
|
|
||||||
DoSetText(m_text);
|
DoSetText(text);
|
||||||
}
|
}
|
||||||
|
|
||||||
wxMenuItem::~wxMenuItem()
|
wxMenuItem::~wxMenuItem()
|
||||||
|
Reference in New Issue
Block a user