1 /**************************************************************************
2 * Copyright(c) 1998-2003, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
16 /////////////////////////////////////////////////////////////////////////
17 // ALICE SHUTTER FRAME CLASS //
18 // Author: Mayeul ROUSSELET //
19 // e-mail: Mayeul.Rousselet@cern.ch //
20 // Last update:26/08/2003 //
21 /////////////////////////////////////////////////////////////////////////
25 #include <TGShutter.h>
27 #include "AliDetectorFrame.h"
28 #include "AliDisplay2.h"
29 #include "AliShutterItem.h"
31 #include "AliShutterFrame.h"
34 ClassImp(AliShutterFrame);
36 //_____________________________________________________________
37 AliShutterFrame::AliShutterFrame(TGCompositeFrame *p, UInt_t /*w*/, UInt_t h)
40 fShutter = new TGShutter(p,kSunkenFrame);
41 fLayout = new TGLayoutHints(kLHintsExpandY | kLHintsTop | kLHintsLeft);
42 fMainFrame = (TGCompositeFrame *) fShutter;
45 AliShutterItem *item = new AliShutterItem(fShutter,"Event",kIdsEVENT);
47 item->AddPictureButton("next.xpm","Show next event",kIdbNextEVENT);
48 item->AddPictureButton("prev.xpm","Show previous event",kIdbPrevEVENT);
51 item = new AliShutterItem(fShutter,"View",kIdsVIEW);
52 item->AddPictureButton("top.xpm","Top view",kIdbTOPVIEW);
53 item->AddPictureButton("side.xpm","Side view",kIdbSIDEVIEW);
54 item->AddPictureButton("front.xpm","Front view",kIdbFRONTVIEW);
55 item->AddPictureButton("four.xpm","Four views",kIdbALLVIEW);
58 item = new AliShutterItem(fShutter,"Detectors",kIdsDETECTORS);
59 TGCompositeFrame *frame = item->GetShutterItemFrame();
60 fDetectorFrameLayout = new TGLayoutHints( kLHintsTop | kLHintsLeft| kLHintsExpandX | kLHintsCenterX,5,5,5,5);
61 fDetectorFrame = new AliDetectorFrame(frame,200,200,item->GetShutterItem()->GetDefaultFrameBackground());
62 frame->AddFrame(fDetectorFrame->GetDetectorFrame(),fDetectorFrameLayout);
65 item = new AliShutterItem(fShutter,"Options",kIdsOPTIONS);
66 item->AddCheckButton("Display Hits",kIdbCheckHITS);
67 item->AddCheckButton("Display Clusters",kIdbCheckCLUSTERS);
68 item->AddCheckButton("Display HLT Clusters",kIdbCheckHLT);
69 // item->AddCheckButton("Display Tracks",kIdbCheckTRACKS);
71 fMainFrame->Resize(150,h);
74 //_____________________________________________________________
75 AliShutterFrame::~AliShutterFrame(void)
81 delete fDetectorFrame;
82 delete fDetectorFrameLayout;