CMS 3D CMS Logo

FWViewManagerBase.h
Go to the documentation of this file.
1 #ifndef Fireworks_Core_FWViewManagerBase_h
2 #define Fireworks_Core_FWViewManagerBase_h
3 // -*- C++ -*-
4 //
5 // Package: Core
6 // Class : FWViewManagerBase
7 //
16 //
17 // Original Author:
18 // Created: Sat Jan 5 10:29:00 EST 2008
19 //
20 
21 // system include files
22 #include <string>
23 #include <vector>
24 #include <set>
25 #include <map>
26 
27 // user include files
28 
29 //Needed for gccxml
31 
32 // forward declarations
33 class FWEventItem;
34 class TClass;
35 class FWGeometry;
36 class FWModelId;
38 class FWColorManager;
40 
41 namespace fireworks
42 {
43 class Context;
44 }
45 
47 {
48 
49 public:
50  virtual ~FWViewManagerBase();
51 
52  // ---------- const member functions ---------------------
53  virtual FWTypeToRepresentations supportedTypesAndRepresentations() const = 0;
54  // ---------- static member functions --------------------
55 
56  // ---------- member functions ---------------------------
57  virtual void newItem(const FWEventItem*) = 0;
58 
59  virtual void setContext(const fireworks::Context* x) { m_context = x; }
60 
61  void setChangeManager(FWModelChangeManager* iCM);
62  void setColorManager(FWColorManager* iCM);
63 
64 
65  void modelChangesComingSlot();
66  void modelChangesDoneSlot();
67  void colorsChangedSlot();
68  virtual void eventBegin(){
69  };
70  virtual void eventEnd(){
71  };
72 
73  // ---------- const member functions ---------------------
74 
75  const fireworks::Context& context() const { return *m_context; }
76 
77 protected:
79 
84  void* createInstanceOf(const TClass* iBaseClass,
85  const char* iNameOfClass);
86 
88  virtual void modelChangesComing() = 0;
89  virtual void modelChangesDone() = 0;
90  virtual void colorsChanged() = 0;
91 
92  FWModelChangeManager& changeManager() const;
93  FWColorManager& colorManager() const;
94 
95 private:
96  FWViewManagerBase(const FWViewManagerBase&) = delete; // stop default
97 
98  const FWViewManagerBase& operator=(const FWViewManagerBase&) = delete; // stop default
99 
100  // ---------- member data --------------------------------
102 
105 };
106 
107 
108 #endif
const fireworks::Context & context() const
virtual void eventEnd()
virtual void setContext(const fireworks::Context *x)
const fireworks::Context * m_context
FWModelChangeManager * m_changeManager
FWColorManager * m_colorManager
virtual void eventBegin()