pqSelectionReaction.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Kitware Inc.
2 // SPDX-FileCopyrightText: Copyright (c) Sandia Corporation
3 // SPDX-License-Identifier: BSD-3-Clause
4 #ifndef pqSelectionReaction_h
5 #define pqSelectionReaction_h
6 
7 #include "pqReaction.h"
8 #include <QPointer> // needed for QPointer.
9 
10 class QActionGroup;
11 
17 {
18  Q_OBJECT
19  typedef pqReaction Superclass;
20 
21 public:
31  pqSelectionReaction(QAction* parent, QActionGroup* modifierGroup = nullptr);
32 
33 protected Q_SLOTS:
37  virtual void modifiersChanged() {}
38 
39 protected: // NOLINT(readability-redundant-access-specifiers)
43  virtual int getSelectionModifier();
44 
48  virtual void uncheckSelectionModifiers();
49 
53  virtual void disableSelectionModifiers(bool disable);
54 
55  QPointer<QActionGroup> ModifierGroup;
56 
57 private:
58  Q_DISABLE_COPY(pqSelectionReaction)
59 };
60 
61 #endif
QPointer< QActionGroup > ModifierGroup
#define PQAPPLICATIONCOMPONENTS_EXPORT
virtual void modifiersChanged()
called when modifier group is changed.
This is a superclass just to make it easier to collect all such reactions.
Definition: pqReaction.h:25
Generric reaction for creating selections on views.