diff --git a/src/plugins/debugger/debuggerplugin.cpp b/src/plugins/debugger/debuggerplugin.cpp index 7a605bcf072939e083d391ccd1f98a6526376342..cfff7213ce6c2f7402a914160adfdc309a36adb5 100644 --- a/src/plugins/debugger/debuggerplugin.cpp +++ b/src/plugins/debugger/debuggerplugin.cpp @@ -383,14 +383,13 @@ const char * const ADD_TO_WATCH2 = "Debugger.AddToWatch2"; const char * const OPERATE_BY_INSTRUCTION = "Debugger.OperateByInstruction"; const char * const FRAME_UP = "Debugger.FrameUp"; const char * const FRAME_DOWN = "Debugger.FrameDown"; -const char * const DEBUG_KEY = "F5"; #ifdef Q_WS_MAC -const char * const STOP_KEY = "Shift+F5"; +const char * const STOP_KEY = "Shift+Ctrl+Y"; const char * const RESET_KEY = "Ctrl+Shift+F5"; -const char * const STEP_KEY = "F7"; -const char * const STEPOUT_KEY = "Shift+F7"; -const char * const NEXT_KEY = "F6"; +const char * const STEP_KEY = "Ctrl+Shift+I"; +const char * const STEPOUT_KEY = "Ctrl+Shift+T"; +const char * const NEXT_KEY = "Ctrl+Shift+O"; const char * const REVERSE_KEY = ""; const char * const RUN_TO_LINE_KEY = "Shift+F8"; const char * const RUN_TO_FUNCTION_KEY = "Ctrl+F6"; @@ -1445,7 +1444,6 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments, QString *er cmd = am->registerAction(m_actions.interruptAction, PE::DEBUG, m_interruptibleContext); - cmd->setDefaultKeySequence(QKeySequence(Constants::STOP_KEY)); cmd->setDefaultText(tr("Interrupt Debugger")); cmd = am->registerAction(m_actions.undisturbableAction, @@ -2291,7 +2289,7 @@ void DebuggerPluginPrivate::updateState(DebuggerEngine *engine) m_actions.continueAction->setEnabled(false); m_actions.stopAction->setEnabled(false); am->command(Constants::STOP)->setKeySequence(QKeySequence()); - am->command(PE::DEBUG)->setKeySequence(QKeySequence(DEBUG_KEY)); + am->command(PE::DEBUG)->setKeySequence(QKeySequence(ProjectExplorer::Constants::DEBUG_KEY)); core->updateAdditionalContexts(m_anyContext, Context()); } else if (m_state == InferiorStopOk) { // F5 continues, Shift-F5 kills. It is "continuable". @@ -2299,7 +2297,7 @@ void DebuggerPluginPrivate::updateState(DebuggerEngine *engine) m_actions.continueAction->setEnabled(true); m_actions.stopAction->setEnabled(true); am->command(Constants::STOP)->setKeySequence(QKeySequence(STOP_KEY)); - am->command(PE::DEBUG)->setKeySequence(QKeySequence(DEBUG_KEY)); + am->command(PE::DEBUG)->setKeySequence(QKeySequence(ProjectExplorer::Constants::DEBUG_KEY)); core->updateAdditionalContexts(m_anyContext, m_continuableContext); } else if (m_state == InferiorRunOk) { // Shift-F5 interrupts. It is also "interruptible". @@ -2315,7 +2313,7 @@ void DebuggerPluginPrivate::updateState(DebuggerEngine *engine) m_actions.continueAction->setEnabled(false); m_actions.stopAction->setEnabled(false); am->command(Constants::STOP)->setKeySequence(QKeySequence()); - am->command(PE::DEBUG)->setKeySequence(QKeySequence(DEBUG_KEY)); + am->command(PE::DEBUG)->setKeySequence(QKeySequence(ProjectExplorer::Constants::DEBUG_KEY)); //core->updateAdditionalContexts(m_anyContext, m_finishedContext); m_codeModelSnapshot = CPlusPlus::Snapshot(); core->updateAdditionalContexts(m_anyContext, Context()); diff --git a/src/plugins/projectexplorer/projectexplorer.cpp b/src/plugins/projectexplorer/projectexplorer.cpp index 77112737a5719003f769d6720bab8c99f2c03d07..b43d46bd970e5ec55df95df28f3c4e8773ffbd69 100644 --- a/src/plugins/projectexplorer/projectexplorer.cpp +++ b/src/plugins/projectexplorer/projectexplorer.cpp @@ -690,7 +690,7 @@ bool ProjectExplorerPlugin::initialize(const QStringList &arguments, QString *er cmd->setAttribute(Core::Command::CA_UpdateText); cmd->setAttribute(Core::Command::CA_UpdateIcon); cmd->setDefaultText(tr("Start Debugging")); - cmd->setDefaultKeySequence(QKeySequence(tr("F5"))); + cmd->setDefaultKeySequence(QKeySequence(Constants::DEBUG_KEY)); mstartdebugging->addAction(cmd, Core::Constants::G_DEFAULT_ONE); modeManager->addAction(cmd, Constants::P_ACTION_DEBUG); diff --git a/src/plugins/projectexplorer/projectexplorerconstants.h b/src/plugins/projectexplorer/projectexplorerconstants.h index c92f1019f6a2a5fb167c05495ce48c6c5972835d..0a36560a10fa15697fcad0eb180d03e6a31058e3 100644 --- a/src/plugins/projectexplorer/projectexplorerconstants.h +++ b/src/plugins/projectexplorer/projectexplorerconstants.h @@ -226,6 +226,12 @@ const char * const DEFAULT_DEPLOYCONFIGURATION_ID = "ProjectExplorer.DefaultDepl // Run Configuration defaults: const int QML_DEFAULT_DEBUG_SERVER_PORT = 3768; +#ifdef Q_OS_MAC +const char * const DEBUG_KEY = "Ctrl+Y"; +#else +const char * const DEBUG_KEY = "F5"; +#endif + } // namespace Constants } // namespace ProjectExplorer