Commit 7e49c4ef authored by John Tourtellott's avatar John Tourtellott Committed by Kitware Robot
Browse files

Merge topic 'default-ui-layout'

002d651f

 Configure default layout with minimal dock widgets
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Merge-request: !766
parents 796f253e 002d651f
Pipeline #202644 failed with stages
......@@ -37,6 +37,7 @@
#include "pqTestUtility.h"
#include <QAction>
#include <QDockWidget>
#include <QList>
#include <QToolBar>
......@@ -358,6 +359,37 @@ void mbMainWindow::postParaViewSetup()
}
#endif
QList<QDockWidget*> all_docks = this->findChildren<QDockWidget*>();
QDockWidget* attDW = nullptr;
QDockWidget* resDW = nullptr;
foreach (QDockWidget* dw, all_docks)
{
if (dw->objectName() == "pqSMTKAttributePanel")
{
dw->setVisible(true);
attDW = dw;
}
else if (dw->objectName() == "pqSMTKResourcePanel")
{
dw->setVisible(true);
resDW = dw;
}
else if (dw->objectName() == "outputWidgetDock")
{
dw->setVisible(true);
this->resizeDocks({ dw }, { 200 }, Qt::Vertical);
}
else
{
dw->setVisible(false);
}
}
if ((attDW != nullptr) && (resDW != nullptr))
{
this->tabifyDockWidget(resDW, attDW);
}
// Enable delete from the properties panel.
auto actionDel = new QAction(this);
auto reactionDel = new pqDeleteReaction(actionDel);
......@@ -375,6 +407,7 @@ void mbMainWindow::postParaViewSetup()
{
pvapp->loadConfiguration(root + QString("/") + file);
}
hideToolBar(this, "&Measurement Tools");
// Set up but hide the pipeline browser dock-widget by default.
pqParaViewMenuBuilders::buildPipelineBrowserContextMenu(
......@@ -453,6 +486,7 @@ void mbMainWindow::togglePostProcessingMode(bool enablePostProcessing)
showToolBar(this, "&Data Analysis");
showToolBar(this, "VCR Controls");
showToolBar(this, "Current Time Controls");
showToolBar(this, "Active Variable Controls");
showAction(findToolBar(this, "Main Controls"), "Find data...");
showAction(findActionByName(this, "actionFileLoadServerState"));
......@@ -480,6 +514,7 @@ void mbMainWindow::togglePostProcessingMode(bool enablePostProcessing)
hideToolBar(this, "&Data Analysis");
hideToolBar(this, "VCR Controls");
hideToolBar(this, "Current Time Controls");
hideToolBar(this, "Active Variable Controls");
hideAction(findToolBar(this, "Main Controls"), "Find data...");
hideAction(findActionByName(this, "actionFileLoadServerState"));
......
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