pqAnimationViewWidget.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 pqAnimationViewWidget_h
5 #define pqAnimationViewWidget_h
6 
7 #include "pqComponentsModule.h"
8 #include <QWidget>
9 
10 #include "vtkParaViewDeprecation.h" // for PARAVIEW_DEPRECATED_IN_5_12_0
11 
13 class pqAnimationScene;
14 class pqAnimationTrack;
15 class pqPipelineSource;
16 class pqView;
17 class vtkSMProxy;
18 
26  "Use `pqTimeManagerWidget` instead") PQCOMPONENTS_EXPORT pqAnimationViewWidget : public QWidget
27 {
28  Q_OBJECT
29  typedef QWidget Superclass;
30 
31 public:
32  pqAnimationViewWidget(QWidget* parent = nullptr);
33  ~pqAnimationViewWidget() override;
34 
35 public Q_SLOTS: // NOLINT(readability-redundant-access-specifiers)
36 
40  void setScene(pqAnimationScene* scene);
41 
42 protected Q_SLOTS:
43 
48  void onSceneCuesChanged();
49 
53  void keyFramesChanged(QObject*);
54 
58  void updateSceneTimeRange();
62  void updateSceneTime();
66  void updateTicks();
67 
68  // called when track is double clicked
69  void trackSelected(pqAnimationTrack* track);
70 
71  // called when play mode changes
72  void updatePlayMode();
73 
74  // called when number of keyframe/timesteps changed
75  void updateStrideRange();
76 
80  void toggleTrackEnabled(pqAnimationTrack* track);
81 
82  // called when deleting a track
83  void deleteTrack(pqAnimationTrack* track);
84  // called when creating a track
85  void createTrack();
86 
91  void createPythonTrack();
92 
93  // set active view changed
94  void setActiveView(pqView*);
95  // set the current proxy selection
96  void setCurrentSelection(pqPipelineSource*);
97  void setCurrentProxy(vtkSMProxy* pxy);
98 
99  // sets the current time
100  void setCurrentTime(double);
101  void setKeyFrameTime(pqAnimationTrack*, pqAnimationKeyFrame*, int, double);
102 
103  // update the time labels
104  void onTimeLabelChanged();
105 
106  // called when the user selects a proxy in the combo box
107  void selectedDataProxyChanged(vtkSMProxy*);
108 
109  // called when the user accepts the change data proxy dialog
110  // when configuring the follow-data animation
111  void changeDataProxyDialogAccepted();
112 
113  void generalSettingsChanged();
114 
115  void onStrideChanged();
116 
117 private:
118  Q_DISABLE_COPY(pqAnimationViewWidget)
119 
120  class pqInternal;
121  pqInternal* Internal = nullptr;
122 };
123 
124 #endif
#define PARAVIEW_DEPRECATED_IN_5_12_0(reason)
#define PQCOMPONENTS_EXPORT
This is a PQ abstraction of a generic view module.
Definition: pqView.h:26
This is the Animation panel widget.
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:140
PQ representation for a vtkSMProxy that can be involved in a pipeline.
pqAnimationScene is a representation for a vtkSMAnimationScene proxy.
pqTimeManagerWidget is the main widget for the Time Manager dock.