forked from qt-creator/qt-creator
Fix particles play button state when scene changes
Add play button state to the scene state. Task-number: QDS-5499 Change-Id: Id3035de439aa80fd782348cf89a1d8456a7dd006 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This commit is contained in:
@@ -108,6 +108,7 @@ void Edit3DView::updateActiveScene3D(const QVariantMap &sceneState)
|
||||
const QString orientationKey = QStringLiteral("globalOrientation");
|
||||
const QString editLightKey = QStringLiteral("showEditLight");
|
||||
const QString gridKey = QStringLiteral("showGrid");
|
||||
const QString particlesPlayKey = QStringLiteral("particlePlay");
|
||||
|
||||
if (sceneState.contains(sceneKey)) {
|
||||
qint32 newActiveScene = sceneState[sceneKey].value<qint32>();
|
||||
@@ -151,6 +152,11 @@ void Edit3DView::updateActiveScene3D(const QVariantMap &sceneState)
|
||||
m_showGridAction->action()->setChecked(sceneState[gridKey].toBool());
|
||||
else
|
||||
m_showGridAction->action()->setChecked(false);
|
||||
|
||||
if (sceneState.contains(particlesPlayKey))
|
||||
m_particlesPlayAction->action()->setChecked(sceneState[particlesPlayKey].toBool());
|
||||
else
|
||||
m_particlesPlayAction->action()->setChecked(true);
|
||||
}
|
||||
|
||||
void Edit3DView::modelAttached(Model *model)
|
||||
|
||||
Reference in New Issue
Block a user