fixed appending menu items for a (popup) menu with a title broken by last change (and also fixed inserting in this case which didn't work even before last change)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@34749 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -390,6 +390,10 @@ bool wxMenu::DoInsertOrAppend(wxMenuItem *pItem, size_t pos)
|
|||||||
pos = GetMenuItemCount() - 1;
|
pos = GetMenuItemCount() - 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// adjust position to account for the title, if any
|
||||||
|
if ( !m_title.empty() )
|
||||||
|
pos += 2; // for the title itself and its separator
|
||||||
|
|
||||||
BOOL ok = false;
|
BOOL ok = false;
|
||||||
|
|
||||||
// check if we have something more than a simple text item
|
// check if we have something more than a simple text item
|
||||||
|
Reference in New Issue
Block a user