Git: Make "Create Repository" action local

Change-Id: Id52d145ca6a8120fb28c6a800bfd4ac497e4260d
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
Robert Loehning
2016-02-03 16:24:36 +01:00
parent 5c81e26a72
commit fa3a35e346
2 changed files with 3 additions and 5 deletions

View File

@@ -593,10 +593,10 @@ bool GitPlugin::initialize(const QStringList &arguments, QString *errorMessage)
createRepositoryAction(gitContainer, tr("Actions on Commits..."), "Git.ChangeActions",
context, false, [this] { startChangeRelatedAction("Git.ChangeActions"); });
m_createRepositryAction = new QAction(tr("Create Repository..."), this);
QAction *createRepositoryAction = new QAction(tr("Create Repository..."), this);
Command *createRepositoryCommand = ActionManager::registerAction(
m_createRepositryAction, "Git.CreateRepository");
connect(m_createRepositryAction, &QAction::triggered, this, &GitPlugin::createRepository);
createRepositoryAction, "Git.CreateRepository");
connect(createRepositoryAction, &QAction::triggered, this, &GitPlugin::createRepository);
gitContainer->addAction(createRepositoryCommand);
// Submit editor
@@ -1273,7 +1273,6 @@ void GitPlugin::updateActions(VcsBasePlugin::ActionState as)
m_remoteDialog->refresh(currentState().topLevel(), false);
m_commandLocator->setEnabled(repositoryEnabled);
m_createRepositryAction->setEnabled(true);
if (!enableMenuAction(as, m_menuAction))
return;
if (repositoryEnabled)