Commit 4429a8de authored by con's avatar con

Make tools menu look better on Linux/Win

parent c14fd1e0
......@@ -203,6 +203,8 @@ const char * const G_EDIT_BLOCKS = "QtCreator.Group.Edit.Blocks";
const char * const G_EDIT_FONT = "QtCreator.Group.Edit.Font";
const char * const G_EDIT_EDITOR = "QtCreator.Group.Edit.Editor";
const char * const G_TOOLS_OPTIONS = "QtCreator.Group.Tools.Options";
// window menu groups
const char * const G_WINDOW_SIZE = "QtCreator.Group.Window.Size";
const char * const G_WINDOW_PANES = "QtCreator.Group.Window.Panes";
......
......@@ -455,10 +455,6 @@ void ExternalToolManager::initialize()
ActionContainer *mtools = am->actionContainer(Constants::M_TOOLS);
Command *cmd;
QAction *sep = new QAction(this);
sep->setSeparator(true);
cmd = am->registerAction(sep, Id("Tools.Separator"), Context(Constants::C_GLOBAL));
mtools->addAction(cmd, Constants::G_DEFAULT_THREE);
mtools->addMenu(mexternaltools, Constants::G_DEFAULT_THREE);
QMap<QString, ActionContainer *> categoryMenus;
......
......@@ -562,10 +562,6 @@ void MainWindow::registerDefaultActions()
cmd = createSeparator(am, this, QLatin1String("QtCreator.Edit.Sep.Advanced"), globalContext);
medit->addAction(cmd, Constants::G_EDIT_ADVANCED);
// Tools menu separators
cmd = createSeparator(am, this, QLatin1String("QtCreator.Tools.Sep.Options"), globalContext);
mtools->addAction(cmd, Constants::G_DEFAULT_THREE);
// Return to editor shortcut: Note this requires Qt to fix up
// handling of shortcut overrides in menus, item views, combos....
m_focusToEditor = new QShortcut(this);
......@@ -709,13 +705,16 @@ void MainWindow::registerDefaultActions()
tmpaction->setEnabled(false);
// Options Action
mtools->appendGroup(Constants::G_TOOLS_OPTIONS);
cmd = createSeparator(am, this, QLatin1String("QtCreator.Tools.Sep.Options"), globalContext);
mtools->addAction(cmd, Constants::G_TOOLS_OPTIONS);
m_optionsAction = new QAction(tr("&Options..."), this);
cmd = am->registerAction(m_optionsAction, Constants::OPTIONS, globalContext);
#ifdef Q_WS_MAC
cmd->setDefaultKeySequence(QKeySequence("Ctrl+,"));
cmd->action()->setMenuRole(QAction::PreferencesRole);
#endif
mtools->addAction(cmd, Constants::G_DEFAULT_THREE);
mtools->addAction(cmd, Constants::G_TOOLS_OPTIONS);
connect(m_optionsAction, SIGNAL(triggered()), this, SLOT(showOptionsDialog()));
#ifdef Q_WS_MAC
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment