]> git.uio.no Git - u/mrichter/AliRoot.git/blame - EVE/Reve/TGNewBrowser.h
Record changes.
[u/mrichter/AliRoot.git] / EVE / Reve / TGNewBrowser.h
CommitLineData
32e219c2 1#ifndef ROOT_TGNewBrowser
2#define ROOT_TGNewBrowser
3
4#ifndef ROOT_TGFrame
5#include "TGFrame.h"
6#endif
7
8//#ifndef ROOT_TBrowserImp
9//#include "TBrowserImp.h"
10//#endif
11
12class TGLayoutHints;
13class TGTab;
14class TGListTree;
15class TGListTreeItem;
16class TGPicture;
17class TGLabel;
18class TGComboBox;
19class TGTextEntry;
20class TGTextBuffer;
21class TGTextView;
22class TContextMenu;
23class TRegexp;
24class TGMenuBar;
25class TGPopupMenu;
26class TGStatusBar;
27class TGPictureButton;
28class TGVSplitter;
29class TGHSplitter;
30
31class TGFileBrowser;
32
33class TGNewBrowser : public TGMainFrame { //, public TBrowserImp {
34
35protected:
36
37 TGLayoutHints *fLH0, *fLH1, *fLH2, *fLH3, *fLH4;
38 TGLayoutHints *fLH5, *fLH6, *fLH7;
39 TGTab *fTabLeft;
40 TGTab *fTabRight;
41 TGTab *fTabBottom;
42 TGTab *fEditTab;
43 TGVerticalFrame *fVf;
44 TGHorizontalFrame *fHf;
45 TGHorizontalFrame *fH1;
46 TGHorizontalFrame *fH2;
47 TGVerticalFrame *fV1;
48 TGVerticalFrame *fV2;
49 TGVSplitter *fVSplitter;
50 TGHSplitter *fHSplitter;
51 TGCompositeFrame *fEditFrame;
52 TGHorizontalFrame *fTopMenuFrame;
53 TGHorizontalFrame *fPreMenuFrame;
54 TGHorizontalFrame *fMenuFrame;
55 TGHorizontalFrame *fToolbarFrame;
56 TGMenuBar *fMenuBar;
57 TGPopupMenu *fMenuFile;
58 TGCompositeFrame *fActMenuBar;
59 TGStatusBar *fStatusBar;
60 Int_t fNbTab[3];
61 Int_t fCrTab[3];
62 Int_t fPid; // current process id
63
64public:
65 enum EInsertPosition {
66 kLeft, kRight, kBottom
67 };
68
69 TGNewBrowser(const char *name = "ROOT Browser", UInt_t width = 800, UInt_t height = 500, Bool_t initshow=kTRUE);
70 TGNewBrowser(const char *name, Int_t x, Int_t y, UInt_t width, UInt_t height, Bool_t initshow=kTRUE);
71 virtual ~TGNewBrowser();
72
73 TGFileBrowser* MakeFileBrowser();
74 void InitPlugins();
75
76 void CreateBrowser(const char *name);
77 void CloseWindow();
78 void DoTab(Int_t id);
79 TGFrame *GetActFrame() const { return (TGFrame *)fEditFrame; }
80 TGStatusBar *GetStatusBar() const { return fStatusBar; }
81 TGTab *GetTabLeft() const { return fTabLeft; }
82 TGTab *GetTabRight() const { return fTabRight; }
83 TGTab *GetTabBottom() const { return fTabBottom; }
84 TGTab *GetTab(Int_t pos) const;
85 void SetTab(Int_t pos = kRight, Int_t subpos = -1);
86 void SetTabTitle(const char *title, Int_t pos = kRight, Int_t subpos = -1);
87 void HandleMenu(Int_t id);
88 using TGCompositeFrame::RemoveFrame;
89 void RecursiveReparent(TGPopupMenu *popup);
90 void RemoveFrame(Int_t pos, Int_t subpos);
91 void ShowMenu(TGCompositeFrame *menu);
92 TGCompositeFrame *StartEmbedding(Int_t pos = kRight, Int_t subpos = -1);
93 void StopEmbedding(TGLayoutHints *layout=0);
94 void SwitchMenus(TGCompositeFrame *from);
95
96 virtual void ExecPlugin(const char *fname, Int_t pos = kRight, Int_t subpos = -1);
97 virtual Bool_t HandleKey(Event_t *event);
98
99 // static TBrowserImp *NewBrowser(TBrowser *b = 0, const char *title = "ROOT Browser", UInt_t width = 800, UInt_t height = 500);
100 // static TBrowserImp *NewBrowser(TBrowser *b, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height);
101
102 // overridden from TGMainFrame
103 // void ReallyDelete();
104
105 ClassDef(TGNewBrowser, 0)
106};
107
108#endif