pqServerDisconnectReaction.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 pqServerDisconnectReaction_h
5 #define pqServerDisconnectReaction_h
6 
7 #include "pqReaction.h"
8 #include "pqTimer.h" // needed for pqTimer.
9 
15 {
16  Q_OBJECT
17  typedef pqReaction Superclass;
18 
19 public:
23  pqServerDisconnectReaction(QAction* parent);
24 
30  static void disconnectFromServer();
31 
37  static bool disconnectFromServerWithWarning();
38 private Q_SLOTS:
39  void updateState();
40 
41 protected:
45  void onTriggered() override;
46 
47  pqTimer UpdateTimer;
48 
49 private:
50  Q_DISABLE_COPY(pqServerDisconnectReaction)
51 };
52 
53 #endif
#define PQAPPLICATIONCOMPONENTS_EXPORT
Reaction to disconnect from a server.
This is a superclass just to make it easier to collect all such reactions.
Definition: pqReaction.h:25
virtual void onTriggered()
Called when the action is triggered.
Definition: pqReaction.h:46