forked from qt-creator/qt-creator
Move Session Manager... menu to Sessions > Manage...
Change-Id: If0f11c8c308069290174aa8cc6081108f9b448a1 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -39,7 +39,7 @@
|
|||||||
|
|
||||||
When you exit \QC, a snapshot of your current workspace is stored as a
|
When you exit \QC, a snapshot of your current workspace is stored as a
|
||||||
\e session. To restore the session automatically when you start \QC,
|
\e session. To restore the session automatically when you start \QC,
|
||||||
select \uicontrol {File > Session Manager > Restore last session on startup}.
|
select \uicontrol {File > Sessions > Manage > Restore last session on startup}.
|
||||||
|
|
||||||
When you open or create any of the following items, they automatically
|
When you open or create any of the following items, they automatically
|
||||||
become a part of the session:
|
become a part of the session:
|
||||||
@@ -68,7 +68,7 @@
|
|||||||
to working on the first project, switch to the saved session. \QC opens the
|
to working on the first project, switch to the saved session. \QC opens the
|
||||||
projects and files that belong to the session.
|
projects and files that belong to the session.
|
||||||
|
|
||||||
To manage sessions, select \uicontrol File > \uicontrol {Session Manager}.
|
To manage sessions, select \uicontrol File > \uicontrol Sessions > \uicontrol Manage.
|
||||||
|
|
||||||
\image qtcreator-session-manager.png
|
\image qtcreator-session-manager.png
|
||||||
|
|
||||||
|
@@ -816,9 +816,9 @@ bool ProjectExplorerPlugin::initialize(const QStringList &arguments, QString *er
|
|||||||
dd, &ProjectExplorerPluginPrivate::updateSessionMenu);
|
dd, &ProjectExplorerPluginPrivate::updateSessionMenu);
|
||||||
|
|
||||||
// session manager action
|
// session manager action
|
||||||
dd->m_sessionManagerAction = new QAction(tr("Session &Manager..."), this);
|
dd->m_sessionManagerAction = new QAction(tr("&Manage..."), this);
|
||||||
cmd = ActionManager::registerAction(dd->m_sessionManagerAction, Constants::NEWSESSION);
|
dd->m_sessionMenu->addAction(dd->m_sessionManagerAction);
|
||||||
mfile->addAction(cmd, Core::Constants::G_FILE_OPEN);
|
dd->m_sessionMenu->addSeparator();
|
||||||
cmd->setDefaultKeySequence(QKeySequence());
|
cmd->setDefaultKeySequence(QKeySequence());
|
||||||
|
|
||||||
|
|
||||||
@@ -3305,6 +3305,8 @@ void ProjectExplorerPluginPrivate::handleSetStartupProject()
|
|||||||
void ProjectExplorerPluginPrivate::updateSessionMenu()
|
void ProjectExplorerPluginPrivate::updateSessionMenu()
|
||||||
{
|
{
|
||||||
m_sessionMenu->clear();
|
m_sessionMenu->clear();
|
||||||
|
dd->m_sessionMenu->addAction(dd->m_sessionManagerAction);
|
||||||
|
dd->m_sessionMenu->addSeparator();
|
||||||
QActionGroup *ag = new QActionGroup(m_sessionMenu);
|
QActionGroup *ag = new QActionGroup(m_sessionMenu);
|
||||||
connect(ag, &QActionGroup::triggered, this, &ProjectExplorerPluginPrivate::setSession);
|
connect(ag, &QActionGroup::triggered, this, &ProjectExplorerPluginPrivate::setSession);
|
||||||
const QString activeSession = SessionManager::activeSession();
|
const QString activeSession = SessionManager::activeSession();
|
||||||
|
Reference in New Issue
Block a user