|
|
|
@ -939,27 +939,27 @@ void MainWindow::InitActions()
|
|
|
|
.Connect(&QAction::triggered, this, &MainWindow::OnRefreshAudioSystem);
|
|
|
|
.Connect(&QAction::triggered, this, &MainWindow::OnRefreshAudioSystem);
|
|
|
|
|
|
|
|
|
|
|
|
// Game actions
|
|
|
|
// Game actions
|
|
|
|
am->AddAction(ID_VIEW_SWITCHTOGAME, tr("Play &Game"))
|
|
|
|
am->AddAction(ID_VIEW_SWITCHTOGAME, tr("Play Game"))
|
|
|
|
.SetIcon(QIcon(":/stylesheet/img/UI20/toolbar/Play.svg"))
|
|
|
|
.SetIcon(QIcon(":/stylesheet/img/UI20/toolbar/Play.svg"))
|
|
|
|
|
|
|
|
.SetToolTip(tr("Play Game"))
|
|
|
|
|
|
|
|
.SetStatusTip(tr("Activate the game input mode"))
|
|
|
|
|
|
|
|
.SetCheckable(true)
|
|
|
|
|
|
|
|
.RegisterUpdateCallback(cryEdit, &CCryEditApp::OnUpdatePlayGame);
|
|
|
|
|
|
|
|
am->AddAction(ID_VIEW_SWITCHTOGAME_VIEWPORT, tr("Play Game"))
|
|
|
|
.SetShortcut(tr("Ctrl+G"))
|
|
|
|
.SetShortcut(tr("Ctrl+G"))
|
|
|
|
.SetToolTip(tr("Play Game (Ctrl+G)"))
|
|
|
|
.SetToolTip(tr("Play Game (Ctrl+G)"))
|
|
|
|
.SetStatusTip(tr("Activate the game input mode"))
|
|
|
|
.SetStatusTip(tr("Activate the game input mode"))
|
|
|
|
.SetApplyHoverEffect()
|
|
|
|
|
|
|
|
.SetCheckable(true)
|
|
|
|
|
|
|
|
.RegisterUpdateCallback(cryEdit, &CCryEditApp::OnUpdatePlayGame);
|
|
|
|
.RegisterUpdateCallback(cryEdit, &CCryEditApp::OnUpdatePlayGame);
|
|
|
|
am->AddAction(ID_VIEW_SWITCHTOGAME_FULLSCREEN, tr("Play &Game (Maximized)"))
|
|
|
|
am->AddAction(ID_VIEW_SWITCHTOGAME_FULLSCREEN, tr("Play Game (Maximized)"))
|
|
|
|
.SetShortcut(tr("Ctrl+Shift+G"))
|
|
|
|
.SetShortcut(tr("Ctrl+Shift+G"))
|
|
|
|
.SetStatusTip(tr("Activate the game input mode (maximized)"))
|
|
|
|
.SetStatusTip(tr("Activate the game input mode (maximized)"))
|
|
|
|
.SetIcon(Style::icon("Play"))
|
|
|
|
.RegisterUpdateCallback(cryEdit, &CCryEditApp::OnUpdatePlayGame);
|
|
|
|
.SetApplyHoverEffect()
|
|
|
|
|
|
|
|
.SetCheckable(true);
|
|
|
|
|
|
|
|
am->AddAction(ID_TOOLBAR_WIDGET_PLAYCONSOLE_LABEL, tr("Play Controls"))
|
|
|
|
am->AddAction(ID_TOOLBAR_WIDGET_PLAYCONSOLE_LABEL, tr("Play Controls"))
|
|
|
|
.SetText(tr("Play Controls"));
|
|
|
|
.SetText(tr("Play Controls"));
|
|
|
|
am->AddAction(ID_SWITCH_PHYSICS, tr("Simulate"))
|
|
|
|
am->AddAction(ID_SWITCH_PHYSICS, tr("Simulate"))
|
|
|
|
.SetIcon(QIcon(":/stylesheet/img/UI20/toolbar/Simulate_Physics.svg"))
|
|
|
|
.SetIcon(QIcon(":/stylesheet/img/UI20/toolbar/Simulate_Physics.svg"))
|
|
|
|
.SetShortcut(tr("Ctrl+P"))
|
|
|
|
.SetShortcut(tr("Ctrl+P"))
|
|
|
|
.SetToolTip(tr("Simulate (Ctrl+P)"))
|
|
|
|
.SetToolTip(tr("Simulate (Ctrl+P)"))
|
|
|
|
.SetCheckable(true)
|
|
|
|
|
|
|
|
.SetStatusTip(tr("Enable processing of Physics and AI."))
|
|
|
|
.SetStatusTip(tr("Enable processing of Physics and AI."))
|
|
|
|
.SetApplyHoverEffect()
|
|
|
|
.SetApplyHoverEffect()
|
|
|
|
.SetCheckable(true)
|
|
|
|
.SetCheckable(true)
|
|
|
|
@ -1266,7 +1266,9 @@ void MainWindow::OnGameModeChanged(bool inGameMode)
|
|
|
|
// block signals on the switch to game actions before setting the checked state, as
|
|
|
|
// block signals on the switch to game actions before setting the checked state, as
|
|
|
|
// setting the checked state triggers the action, which will re-enter this function
|
|
|
|
// setting the checked state triggers the action, which will re-enter this function
|
|
|
|
// and result in an infinite loop
|
|
|
|
// and result in an infinite loop
|
|
|
|
AZStd::vector<QAction*> actions = { m_actionManager->GetAction(ID_VIEW_SWITCHTOGAME), m_actionManager->GetAction(ID_VIEW_SWITCHTOGAME_FULLSCREEN) };
|
|
|
|
AZStd::vector<QAction*> actions = { m_actionManager->GetAction(ID_VIEW_SWITCHTOGAME_VIEWPORT),
|
|
|
|
|
|
|
|
m_actionManager->GetAction(ID_VIEW_SWITCHTOGAME_FULLSCREEN),
|
|
|
|
|
|
|
|
m_actionManager->GetAction(ID_VIEW_SWITCHTOGAME)};
|
|
|
|
for (auto action : actions)
|
|
|
|
for (auto action : actions)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
action->blockSignals(true);
|
|
|
|
action->blockSignals(true);
|
|
|
|
|