12 #ifndef ROOT_TGeoTabManager
13 #define ROOT_TGeoTabManager
23 class TGCompositeFrame;
40 class TGeoTransientPanel;
42 class TGeoTabManager :
public TObject {
43 friend class TGeoManagerEditor;
45 TGedEditor *fGedEditor;
49 TGeoTransientPanel *fShapePanel;
50 TGeoTransientPanel *fMediumPanel;
51 TGeoTransientPanel *fMaterialPanel;
52 TGeoTransientPanel *fMatrixPanel;
53 TGCompositeFrame *fVolumeTab;
55 static TMap fgEditorToMgrMap;
57 void GetEditors(TClass *cl);
59 TGeoTabManager(TGedEditor *ged);
60 virtual ~TGeoTabManager();
62 static TGeoTabManager *GetMakeTabManager(TGedEditor *ged);
63 static void Cleanup(TGCompositeFrame *frame);
64 TVirtualPad *GetPad()
const {
return fPad;}
65 TGTab *GetTab()
const {
return fTab;}
66 Int_t GetTabIndex()
const;
67 static void MoveFrame(TGCompositeFrame *fr, TGCompositeFrame *p);
68 void SetVolTabEnabled(Bool_t flag=kTRUE);
69 void SetModel(TObject *model);
72 void GetShapeEditor(TGeoShape *shape);
73 void GetVolumeEditor(TGeoVolume *vol);
74 void GetMatrixEditor(TGeoMatrix *matrix);
75 void GetMediumEditor(TGeoMedium *medium);
76 void GetMaterialEditor(TGeoMaterial *material);
78 TGCompositeFrame *GetVolumeTab()
const {
return fVolumeTab;}
79 TGeoVolume *GetVolume()
const {
return fVolume;}
81 ClassDef(TGeoTabManager, 0)
92 class TGeoTreeDialog :
public TGTransientFrame {
95 static TObject *fgSelectedObj;
100 TGTextButton *fClose;
102 virtual void BuildListTree() = 0;
103 virtual void ConnectSignalsToSlots() = 0;
105 TGeoTreeDialog(TGFrame *caller,
const TGWindow *main, UInt_t w = 1, UInt_t h = 1);
106 virtual ~TGeoTreeDialog();
108 static TObject *GetSelected();
110 virtual void DoClose() = 0;
111 virtual void DoItemClick(TGListTreeItem *item, Int_t btn) = 0;
112 void DoSelect(TGListTreeItem *item);
114 ClassDef(TGeoTreeDialog, 0)
125 class TGeoVolumeDialog :
public TGeoTreeDialog {
128 virtual void BuildListTree();
129 virtual void ConnectSignalsToSlots();
132 TGeoVolumeDialog(TGFrame *caller,
const TGWindow *main, UInt_t w = 1, UInt_t h = 1);
133 virtual ~TGeoVolumeDialog() {;}
136 virtual void DoClose();
137 virtual void DoItemClick(TGListTreeItem *item, Int_t btn);
139 ClassDef(TGeoVolumeDialog, 0)
150 class TGeoShapeDialog :
public TGeoTreeDialog {
153 virtual void BuildListTree();
154 virtual void ConnectSignalsToSlots();
157 TGeoShapeDialog(TGFrame *caller,
const TGWindow *main, UInt_t w = 1, UInt_t h = 1);
158 virtual ~TGeoShapeDialog() {;}
161 virtual void DoClose();
162 virtual void DoItemClick(TGListTreeItem *item, Int_t btn);
164 ClassDef(TGeoShapeDialog, 0)
175 class TGeoMediumDialog :
public TGeoTreeDialog {
178 virtual void BuildListTree();
179 virtual void ConnectSignalsToSlots();
182 TGeoMediumDialog(TGFrame *caller,
const TGWindow *main, UInt_t w = 1, UInt_t h = 1);
183 virtual ~TGeoMediumDialog() {;}
186 virtual void DoClose();
187 virtual void DoItemClick(TGListTreeItem *item, Int_t btn);
189 ClassDef(TGeoMediumDialog, 0)
200 class TGeoMaterialDialog :
public TGeoTreeDialog {
203 virtual void BuildListTree();
204 virtual void ConnectSignalsToSlots();
207 TGeoMaterialDialog(TGFrame *caller,
const TGWindow *main, UInt_t w = 1, UInt_t h = 1);
208 virtual ~TGeoMaterialDialog() {;}
211 virtual void DoClose();
212 virtual void DoItemClick(TGListTreeItem *item, Int_t btn);
214 ClassDef(TGeoMaterialDialog, 0)
225 class TGeoMatrixDialog :
public TGeoTreeDialog {
228 virtual void BuildListTree();
229 virtual void ConnectSignalsToSlots();
232 TGeoMatrixDialog(TGFrame *caller,
const TGWindow *main, UInt_t w = 1, UInt_t h = 1);
233 virtual ~TGeoMatrixDialog() {;}
236 virtual void DoClose();
237 virtual void DoItemClick(TGListTreeItem *item, Int_t btn);
239 ClassDef(TGeoMatrixDialog, 0)
250 class TGeoTransientPanel :
public TGMainFrame {
251 TGedEditor *fGedEditor;
254 TGCompositeFrame *fTabContainer;
255 TGCompositeFrame *fStyle;
257 TGTextButton *fClose;
260 TGeoTransientPanel(TGedEditor* ged,
const char *name, TObject *obj);
261 virtual ~TGeoTransientPanel();
263 virtual void CloseWindow();
264 virtual void DeleteEditors();
266 TGTab *GetTab()
const {
return fTab;}
267 TGCompositeFrame *GetStyle()
const {
return fStyle;}
268 TObject *GetModel()
const {
return fModel;}
270 void GetEditors(TClass *cl);
273 void SetModel(TObject *model);
275 ClassDef(TGeoTransientPanel, 0)