From 99bbc523f76efcb8b94c4725b0c8c9205297af0f Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Fri, 27 Sep 2019 13:52:42 +0200 Subject: [PATCH] Use QAction::setShortcut() rather than setShortcuts() This is simpler and we don't need a list of shortcuts here, as we only allow specifying a single one anyhow. See https://github.com/wxWidgets/wxWidgets/pull/1544 --- src/qt/menuitem.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/qt/menuitem.cpp b/src/qt/menuitem.cpp index 0792230ad7..a2f84822d6 100644 --- a/src/qt/menuitem.cpp +++ b/src/qt/menuitem.cpp @@ -177,9 +177,7 @@ void wxQtAction::UpdateShortcutsFromLabel(const wxString& text) const wxString accelStr = text.AfterFirst('\t'); if ( !accelStr.empty() ) { - QList shortcuts; - shortcuts.append( QKeySequence( wxQtConvertString(accelStr) ) ); - setShortcuts( shortcuts ); + setShortcut( QKeySequence( wxQtConvertString(accelStr) ) ); } #endif // wxUSE_ACCEL }