ParaView
pqProxyModifiedStateUndoElement.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: pqProxyModifiedStateUndoElement.h
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
26 #ifndef pqProxyModifiedStateUndoElement_h
27 #define pqProxyModifiedStateUndoElement_h
28 
29 #include "pqCoreModule.h"
30 #include "vtkSMUndoElement.h"
31 
32 class pqProxy;
33 
35 {
36 public:
37  static pqProxyModifiedStateUndoElement* New();
39  void PrintSelf(ostream& os, vtkIndent indent);
40 
41  virtual int Undo() { return this->InternalUndoRedo(true) ? 1 : 0; }
42  virtual int Redo() { return this->InternalUndoRedo(false) ? 1 : 0; }
43 
48  void MadeUnmodified(pqProxy*);
49 
54  void MadeUninitialized(pqProxy*);
55 
56 protected:
59 
60  bool InternalUndoRedo(bool undo);
61  vtkTypeUInt32 ProxySourceGlobalId;
62  bool Reverse;
63 
64 private:
66  void operator=(const pqProxyModifiedStateUndoElement&) VTK_DELETE_FUNCTION;
67 };
68 
69 #endif
void PrintSelf(ostream &os, vtkIndent indent)
virtual int Undo()
Undo the operation encapsulated by this element.
This class represents any registered Server Manager proxy.
Definition: pqProxy.h:56
abstract superclass for Server Manager undo elements.
virtual int Redo()
Redo the operation encaspsulated by this element.