Don't expose implementation only class to public under wxQt
No real changes
This commit is contained in:
parent
4682d5606d
commit
03ad7039d6
2 changed files with 6 additions and 6 deletions
|
|
@ -12,7 +12,6 @@
|
|||
#include "wx/bitmap.h"
|
||||
|
||||
class QAction;
|
||||
class wxQtAction;
|
||||
|
||||
class WXDLLIMPEXP_FWD_CORE wxMenu;
|
||||
|
||||
|
|
@ -48,7 +47,7 @@ public:
|
|||
|
||||
private:
|
||||
// Qt is using an action instead of a menu item.
|
||||
wxQtAction *m_qtAction;
|
||||
QAction *m_qtAction;
|
||||
|
||||
wxDECLARE_DYNAMIC_CLASS( wxMenuItem );
|
||||
};
|
||||
|
|
|
|||
|
|
@ -83,9 +83,10 @@ void wxMenuItem::SetItemLabel( const wxString &label )
|
|||
|
||||
wxMenuItemBase::SetItemLabel( qtlabel );
|
||||
|
||||
m_qtAction->UpdateShortcutsFromLabel( qtlabel );
|
||||
auto qtAction = static_cast<wxQtAction *>(m_qtAction);
|
||||
|
||||
m_qtAction->setText( wxQtConvertString( qtlabel ));
|
||||
qtAction->UpdateShortcutsFromLabel( qtlabel );
|
||||
qtAction->setText( wxQtConvertString( qtlabel ));
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -171,14 +172,14 @@ void wxMenuItem::AddExtraAccel(const wxAcceleratorEntry& accel)
|
|||
{
|
||||
wxMenuItemBase::AddExtraAccel(accel);
|
||||
|
||||
m_qtAction->UpdateShortcuts( accel.ToRawString() );
|
||||
static_cast<wxQtAction *>(m_qtAction)->UpdateShortcuts( accel.ToRawString() );
|
||||
}
|
||||
|
||||
void wxMenuItem::ClearExtraAccels()
|
||||
{
|
||||
wxMenuItemBase::ClearExtraAccels();
|
||||
|
||||
m_qtAction->UpdateShortcuts( wxString() );
|
||||
static_cast<wxQtAction *>(m_qtAction)->UpdateShortcuts( wxString() );
|
||||
}
|
||||
#endif // wxUSE_ACCEL
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue