Skip to content

Commit

Permalink
Refs #7363. Switching to different reaction for view settings.
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Reuter committed Sep 4, 2014
1 parent d77cf4f commit 6a7885f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
Expand Up @@ -10,9 +10,9 @@
#include <QPointer>
#include <QWidget>

class pqApplicationSettingsReaction;
class pqLoadDataReaction;
class pqPipelineSource;
class pqViewSettingsReaction;
class vtkSMDoubleVectorProperty;

class QAction;
Expand Down Expand Up @@ -124,7 +124,7 @@ protected slots:
SaveScreenshotReaction *screenShot; ///< Holder for the screen shot reaction
Ui::MdViewerWidgetClass ui; ///< The MD viewer's UI form
QHBoxLayout *viewLayout; ///< Layout manager for the view widget
pqViewSettingsReaction *viewSettings; ///< Holder for the view settings reaction
pqApplicationSettingsReaction *viewSettings; ///< Holder for the view settings reaction
bool viewSwitched;

/// Check the environmental variables.
Expand Down
Expand Up @@ -24,6 +24,7 @@
#include <pqAnimationManager.h>
#include <pqAnimationScene.h>
#include <pqApplicationCore.h>
#include <pqApplicationSettingsReaction.h>
#include <pqLoadDataReaction.h>
#include <pqObjectBuilder.h>
#include <pqParaViewBehaviors.h>
Expand All @@ -32,7 +33,6 @@
#include <pqRenderView.h>
#include <pqSettings.h>
#include <pqStatusBar.h>
#include <pqViewSettingsReaction.h>
#include <vtkSMDoubleVectorProperty.h>
#include <vtkSMPropertyHelper.h>
#include <vtkSMProxyManager.h>
Expand Down Expand Up @@ -647,10 +647,10 @@ void MdViewerWidget::createMenus()
this->screenShot = new SaveScreenshotReaction(screenShotAction);
viewMenu->addAction(screenShotAction);

QAction *settingsAction = new QAction(QApplication::tr("View Settings..."), this);
QAction *settingsAction = new QAction(QApplication::tr("Settings..."), this);
settingsAction->setShortcut(QKeySequence::fromString("Ctrl+Shift+S"));
settingsAction->setStatusTip(QApplication::tr("Show the settings for the current view."));
this->viewSettings = new pqViewSettingsReaction(settingsAction);
this->viewSettings = new pqApplicationSettingsReaction(settingsAction);
viewMenu->addAction(settingsAction);

QMenu *helpMenu = menubar->addMenu(QApplication::tr("&Help"));
Expand Down Expand Up @@ -785,8 +785,6 @@ void MdViewerWidget::connectDialogs()
*/
void MdViewerWidget::updateAppState()
{
this->viewSettings->updateEnableState();

ThreeSliceView *tsv = dynamic_cast<ThreeSliceView *>(this->currentView);
SplatterPlotView *spv = dynamic_cast<SplatterPlotView *>(this->currentView);
if (NULL != tsv || NULL != spv)
Expand Down

0 comments on commit 6a7885f

Please sign in to comment.