00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #include "TEveWindowEditor.h"
00013 #include "TEveWindow.h"
00014
00015 #include "TVirtualPad.h"
00016 #include "TColor.h"
00017
00018
00019 #include "TGLabel.h"
00020 #include "TGButton.h"
00021 #include "TGNumberEntry.h"
00022 #include "TGColorSelect.h"
00023 #include "TGDoubleSlider.h"
00024
00025
00026
00027
00028
00029
00030 ClassImp(TEveWindowEditor);
00031
00032
00033 TEveWindowEditor::TEveWindowEditor(const TGWindow *p, Int_t width, Int_t height,
00034 UInt_t options, Pixel_t back) :
00035 TGedFrame(p, width, height, options | kVerticalFrame, back),
00036 fM(0),
00037 fShowTitleBar(0)
00038 {
00039
00040
00041 MakeTitle("TEveWindow");
00042
00043 fShowTitleBar = new TGCheckButton(this, "Show title-bar");
00044 AddFrame(fShowTitleBar);
00045 fShowTitleBar->Connect("Clicked()", "TEveWindowEditor", this,
00046 "DoShowTitleBar()");
00047 }
00048
00049
00050
00051
00052 void TEveWindowEditor::SetModel(TObject* obj)
00053 {
00054
00055
00056 fM = dynamic_cast<TEveWindow*>(obj);
00057
00058 fShowTitleBar->SetState(fM->GetShowTitleBar() ? kButtonDown : kButtonUp);
00059 }
00060
00061
00062 void TEveWindowEditor::DoShowTitleBar()
00063 {
00064
00065
00066 fM->SetShowTitleBar(fShowTitleBar->IsOn());
00067 Update();
00068 }