Commit 1e26f2af authored by Matthias Möller's avatar Matthias Möller

fix: - use last used renderer for each viewer when restarting OpenFlipper

closes #2362

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@20103 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 6e3f53a8
......@@ -908,6 +908,10 @@ void CoreWidget::slotPostProcessorMenu( QAction * _action) {
void CoreWidget::slotRenderMenu( QAction * _action) {
unsigned int mode = _action->data().toUInt();
renderManager().setActive(mode,PluginFunctions::activeExaminer());
QString defaultRendererKey = "Viewer" + QString::number(PluginFunctions::activeExaminer())+"/DefaultRenderer";
QString defaultRendererName = renderManager()[mode]->name;
OpenFlipperSettings().setValue(defaultRendererKey,defaultRendererName);
}
//=============================================================================
......@@ -886,9 +886,15 @@ void CoreWidget::slotGlobalRendererMenu(QAction * _action) {
unsigned int mode = _action->data().toUInt();
QString defaultRendererName = renderManager()[mode]->name;
// Set renderer for all viewers
for ( int i = 0 ; i < PluginFunctions::viewers() ; ++i)
{
renderManager().setActive(mode,i);
QString defaultRendererKey = "Viewer" + QString::number(i)+"/DefaultRenderer";
OpenFlipperSettings().setValue(defaultRendererKey,defaultRendererName);
}
}
......
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