1 | #ifndef MARS_MBrowser
|
---|
2 | #define MARS_MBrowser
|
---|
3 |
|
---|
4 | #ifndef MARS_MAGIC
|
---|
5 | #include "MAGIC.h"
|
---|
6 | #endif
|
---|
7 |
|
---|
8 | #ifndef ROOT_TGFrame
|
---|
9 | #include <TGFrame.h>
|
---|
10 | #endif
|
---|
11 |
|
---|
12 | class TList;
|
---|
13 | class TGTab;
|
---|
14 | class TGListView;
|
---|
15 | class TGTextEntry;
|
---|
16 | class TGFSComboBox;
|
---|
17 | class TGProgressBar;
|
---|
18 | class TGPictureButton;
|
---|
19 | class TGFileContainer;
|
---|
20 |
|
---|
21 | class MBrowser : public TGTransientFrame
|
---|
22 | {
|
---|
23 | private:
|
---|
24 | TGTab *fTabs;
|
---|
25 |
|
---|
26 | TGFSComboBox *fDir;
|
---|
27 | TGTextEntry *fEntry;
|
---|
28 |
|
---|
29 | TGPictureButton *fCdup;
|
---|
30 | TGPictureButton *fListMode;
|
---|
31 | TGPictureButton *fDetail;
|
---|
32 |
|
---|
33 | TGFileContainer *fFileCont;
|
---|
34 | TGListView *fFileView;
|
---|
35 |
|
---|
36 | const TGPicture *fPic1;
|
---|
37 | const TGPicture *fPic2;
|
---|
38 | const TGPicture *fPic3;
|
---|
39 |
|
---|
40 | void CreateMenuBar();
|
---|
41 | void CreateTab1();
|
---|
42 | void CreateUpperFrame(TGCompositeFrame *frameup);
|
---|
43 | void CreateLowerFrame(TGCompositeFrame *framelow);
|
---|
44 | void CreateDirListMenu(TGCompositeFrame *frame);
|
---|
45 | void CreateDirListBox(TGCompositeFrame *frame);
|
---|
46 |
|
---|
47 | void SetFileName(const char *name);
|
---|
48 |
|
---|
49 | protected:
|
---|
50 | TList *fList;
|
---|
51 | Char_t fInputFile[256];
|
---|
52 |
|
---|
53 | TGCompositeFrame *CreateNewTab(const char *name);
|
---|
54 |
|
---|
55 | void DisplError(const char *txt);
|
---|
56 | void DisplWarning(const char *txt);
|
---|
57 | void DisplInfo(const char *txt);
|
---|
58 |
|
---|
59 | void ChangeDir(const char *txt=NULL);
|
---|
60 |
|
---|
61 | TGProgressBar *CreateProgressBar(TGHorizontalFrame *frame);
|
---|
62 | void DestroyProgressBar(TGProgressBar *bar);
|
---|
63 |
|
---|
64 | TGHorizontalFrame *fTop1;
|
---|
65 | TGHorizontalFrame *fTop2;
|
---|
66 | TGHorizontalFrame *fTop3;
|
---|
67 |
|
---|
68 | public:
|
---|
69 | MBrowser(const TGWindow *main=NULL, const TGWindow *p=NULL,
|
---|
70 | const UInt_t w=500, const UInt_t h=500) ;
|
---|
71 |
|
---|
72 | virtual ~MBrowser();
|
---|
73 |
|
---|
74 | void CloseWindow();
|
---|
75 |
|
---|
76 | Bool_t InputFileSelected();
|
---|
77 |
|
---|
78 | virtual Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2);
|
---|
79 |
|
---|
80 | ClassDef(MBrowser, 0) // Base class for the Gui-Browsers
|
---|
81 | } ;
|
---|
82 |
|
---|
83 | #endif
|
---|
84 |
|
---|
85 |
|
---|