- Timestamp:
- 11/01/01 10:19:46 (23 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/macros/MagicHillas.C
r949 r1023 24 24 25 25 26 void MagicHillas( )26 void MagicHillas(const char *filename="data/camera.root") 27 27 { 28 28 // … … 50 50 51 51 // 52 // The Hillas histograms (MHHillas) could be created automatically53 // but to make sure, that they are not deleted when the macro is54 // finished you must create them yourself and add it to the list55 //56 MHHillas *hists = new MHHillas;57 plist.AddToList(hists);58 59 MHStarMap *smap = new MHStarMap;60 plist.AddToList(smap);61 62 //63 52 // Now setup the tasks and tasklist: 64 53 // … … 76 65 // CalEvents: Calibration Events 77 66 // 78 MReadTree read("Events", "data/octobertest.root");67 MReadTree read("Events", filename); 79 68 // read.AddFile("data/cer000019.root"); 80 69 81 MCerPhotCalc 82 MImgCleanStd 83 MHillasCalc 84 MFillH 85 MFillH 70 MCerPhotCalc ncalc; 71 MImgCleanStd clean; 72 MHillasCalc hcalc; 73 MFillH hfill("MHillas", "MHHillas"); 74 MFillH sfill("MHillas", "MHStarMap"); 86 75 87 MWriteRootFile write("hillas.root"); 76 // 77 // Crete and setup Tasklist 78 // 79 MWriteRootFile write("hillas.root"); 88 80 write.AddContainer("MHillas"); 89 write.AddContainer("MHHillas"); 90 write.AddContainer(smap); 81 write.AddContainer("MHStarMap"); 91 82 92 83 tlist.AddToList(&read); … … 113 104 // After the analysis is finished we can display the histograms 114 105 // 115 hists->Draw();116 smap->Draw();106 plist.FindObject("MHHillas")->DrawClone(); 107 plist.FindObject("MHStarMap")->DrawClone(); 117 108 } 118 109 -
trunk/MagicSoft/Mars/manalysis/MCerPhotPix.h
r1014 r1023 24 24 MCerPhotPix(Int_t pix = -1, Float_t phot=0., Float_t errphot=0.); 25 25 26 void Print(Option_t *opt = NULL) const; 26 Int_t GetPixId() const { return fPixId; } 27 Float_t GetNumPhotons() const { return fPhot; } 28 Float_t GetErrorPhot() const { return fErrPhot; } 27 29 28 Int_t GetPixId() const { return fPixId; } 29 Float_t GetNumPhotons() const { return fPhot; } 30 Float_t GetErrorPhot() const { return fErrPhot; } 30 void SetPixelContent(Int_t pix, Float_t phot, Float_t errphot); 31 31 32 void SetPixelContent(Int_t pix, Float_t phot, Float_t errphot); 32 Bool_t IsPixelUsed() const { return fIsUsed; } 33 void SetPixelUnused() { fIsUsed = kFALSE; } 34 void SetPixelUsed() { fIsUsed = kTRUE; } 33 35 34 Bool_t IsPixelUsed() const { return fIsUsed; } 35 void SetPixelUnused() { fIsUsed = kFALSE; } 36 void SetPixelUsed() { fIsUsed = kTRUE; } 36 void SetCorePixel() { fIsCore = kTRUE; } 37 Bool_t IsCorePixel() const { return fIsCore; } 37 38 38 void SetCorePixel() { fIsCore = kTRUE; }39 Bool_t IsCorePixel() const { return fIsCore;}39 void SetNumPhotons(Float_t f) { fPhot = f; } 40 void SetErrorPhot(Float_t f) { fErrPhot = f; } 40 41 41 void SetNumPhotons(Float_t f) { fPhot = f; } 42 void SetErrorPhot(Float_t f) { fErrPhot = f; } 42 void Print(Option_t *opt = NULL) const; 43 43 44 44 ClassDef(MCerPhotPix, 1) // class containing information about the Cerenkov Photons in a pixel -
trunk/MagicSoft/Mars/mbase/MParList.cc
r1022 r1023 66 66 fContainer = new TOrdCollection; 67 67 fAutodelete = new TOrdCollection; 68 69 fAutodelete->SetOwner();70 68 } 71 69 … … 89 87 MParList::~MParList() 90 88 { 91 if (TestBit(kIsOwner)) 92 fContainer->SetOwner(); 89 const Bool_t isowner = TestBit(kIsOwner); 90 91 // 92 // Case: 93 // 1) MParList is owner of the containers: 94 // All container are stored in fContainer, and become deleted by 95 // 'delete fContainer'. Some of these containers, which were 96 // created automatically are stored in fAutodelete, too. To prevent 97 // double deletion this containers are not deleted by the destructor 98 // of fAutodelete. 99 // 2) MParList is not owner of the containers: 100 // The containers which were Added by AddToList are not touched. 101 // Only the containers which were created automatically are also 102 // automatically deleted. 103 // 104 fContainer->SetOwner(isowner); 105 fAutodelete->SetOwner(!isowner); 93 106 94 107 delete fContainer; … … 113 126 void MParList::SetLogStream(MLog *log) 114 127 { 115 TIter Next(fContainer); 116 117 MParContainer *cont=NULL; 118 119 // 120 // loop over all tasks for preproccesing 121 // 122 while ( (cont=(MParContainer*)Next()) ) 123 cont->SetLogStream(log); 124 128 fContainer->ForEach(MParContainer, SetLogStream)(log); 125 129 MParContainer::SetLogStream(log); 126 130 } … … 209 213 MParContainer *cont = NULL; 210 214 while ((cont=(MParContainer*)Next())) 211 {212 215 AddToList(cont); 213 /* //214 // Get Name of new container215 //216 const char *name = cont->GetName();217 218 //219 // Check if the new container is already existing in the list220 //221 const TObject *objn = fContainer->FindObject(name);222 const TObject *objt = fContainer->FindObject(cont);223 224 if (objn || objt)225 {226 //227 // If the container is already in the list ignore it.228 //229 if (objt || objn==cont)230 {231 *fLog << dbginf << "Warning: Container '" << cont->GetName() << ", 0x" << (void*)cont;232 *fLog << "' already existing in '" << GetName() << "'... ignoring." << endl;233 continue;234 }235 236 //237 // Otherwise add it to the list, but print a warning message238 //239 *fLog << dbginf << "Warning: Container with the same name '" << cont->GetName();240 *fLog << "' already existing in '" << GetName() << "'." << endl;241 *fLog << "You may not be able to get a pointer to container task by name." << endl;242 }243 244 *fLog << "Adding " << name << " to " << GetName() << "... " << flush;245 246 fContainer->Add(cont);247 248 *fLog << "Done." << endl;*/249 }250 216 } 251 217 … … 426 392 void MParList::SetReadyToSave(Bool_t flag) 427 393 { 428 TIter Next(fContainer); 429 430 MParContainer *cont=NULL; 431 432 // 433 // loop over all tasks for preproccesing 434 // 435 while ( (cont=(MParContainer*)Next()) ) 436 cont->SetReadyToSave(flag); 437 394 fContainer->ForEach(MParContainer, SetReadyToSave)(flag); 438 395 MParContainer::SetReadyToSave(flag); 439 396 } … … 445 402 void MParList::Reset() 446 403 { 447 TIter Next(fContainer); 448 449 MParContainer *cont=NULL; 450 451 // 452 // loop over all tasks for preproccesing 453 // 454 while ((cont=(MParContainer*)Next())) 455 cont->Reset(); 404 fContainer->ForEach(MParContainer, Reset)(); 456 405 } 457 406 -
trunk/MagicSoft/Mars/mbase/MTaskList.cc
r1006 r1023 113 113 void MTaskList::SetLogStream(MLog *log) 114 114 { 115 // 116 // create the Iterator over the tasklist 117 // 118 TIter Next(fTasks); 119 120 MTask *task=NULL; 121 122 // 123 // loop over all tasks for preproccesing 124 // 125 while ((task=(MTask*)Next())) 126 task->SetLogStream(log); 127 115 fTasks->ForEach(MTask, SetLogStream)(log); 128 116 MParContainer::SetLogStream(log); 129 117 } … … 383 371 // create the Iterator for the TaskList 384 372 // 385 TIter Next(fTasks); 386 387 MTask *task=NULL; 388 // 389 // loop over all tasks for postprocessing 390 // only tasks which have successfully been preprocessed are postprocessed. 391 // 392 while ( (task=(MTask*)Next()) ) 393 task->PrintStatistics(lvl+1); 373 fTasks->ForEach(MTask, PrintStatistics)(lvl+1); 394 374 395 375 if (lvl==0) -
trunk/MagicSoft/Mars/meventdisp/MGEvtDisplay.cc
r991 r1023 28 28 29 29 #include <TGTab.h> // TGTab 30 #include <TGMenu.h> // TGPopupMenu 31 #include <TCanvas.h> // TCanvas::Print 30 32 #include <TGLabel.h> // TGLabel 31 33 #include <TGButton.h> // TGPictureButton 32 34 #include <TGMsgBox.h> // TGMsgBox 33 35 #include <TGTextEntry.h> // TGTextEntry 36 #include <TGFileDialog.h> // TGFileDialog 34 37 #include <TRootEmbeddedCanvas.h> // TRootEmbeddedCanvas 35 38 … … 46 49 enum MGCamDisplayCommand 47 50 { 48 M_PREVEVT, 49 M_NEXTEVT, 50 M_EVTNUMBER, 51 52 M_PRINT, 53 M_CLOSE 51 kEvtPrev, 52 kEvtNext, 53 kEvtNumber, 54 55 kFileSaveAs, 56 kFileSaveAsRoot, 57 kFileSaveAsC, 58 kFileSaveAsPS, 59 kFileSaveAsEPS, 60 kFileSaveAsGIF, 61 kFilePrint, 62 kClose 54 63 }; 55 64 … … 155 164 // Create the gui elements 156 165 // 157 TGTextButton *prevevt = new TGTextButton(top2, "<< Previous Event", M_PREVEVT);166 TGTextButton *prevevt = new TGTextButton(top2, "<< Previous Event", kEvtPrev); 158 167 prevevt->Associate(this); 159 168 160 169 TGLabel *evtnr = new TGLabel(top2, new TGString("Event: ")); 161 170 162 fTxtEvtNr = new TGTextEntry(top2, new TGTextBuffer(100), M_EVTNUMBER);171 fTxtEvtNr = new TGTextEntry(top2, new TGTextBuffer(100), kEvtNumber); 163 172 fTxtEvtNr->Resize(60, fTxtEvtNr->GetDefaultHeight()); 164 173 fTxtEvtNr->Associate(this); … … 166 175 fNumOfEvts = new TGLabel(top2, "out of Events."); 167 176 168 TGTextButton *nextevt = new TGTextButton (top2, "Next Event >>", M_NEXTEVT);177 TGTextButton *nextevt = new TGTextButton (top2, "Next Event >>", kEvtNext); 169 178 nextevt->Associate(this); 170 179 … … 252 261 void MGEvtDisplay::AddLowFrame(TGHorizontalFrame *frame) 253 262 { 254 TGTextButton *but1 = new TGTextButton(frame, "Print", M_PRINT); 255 TGTextButton *but2 = new TGTextButton(frame, "Close", M_CLOSE); 256 257 but1->Associate(this); 258 but2->Associate(this); 259 260 fList->Add(but1); 261 fList->Add(but2); 263 TGTextButton *but = new TGTextButton(frame, "Close", kClose); 264 265 but->Associate(this); 266 267 fList->Add(but); 262 268 263 269 TGLayoutHints *laybut = new TGLayoutHints(kLHintsLeft, 10, 10, 10, 10); 264 270 fList->Add(laybut); 265 271 266 frame->AddFrame(but1, laybut); 267 frame->AddFrame(but2, laybut); 272 frame->AddFrame(but, laybut); 268 273 } 269 274 … … 330 335 // Constructor 331 336 // 337 void MGEvtDisplay::AddMenuBar() 338 { 339 // 340 // Add all GUI elements and update the event counter 341 // 342 TGLayoutHints *laymenubar = new TGLayoutHints(kLHintsTop|kLHintsLeft|kLHintsExpandX, 2, 2, 2, 2); 343 TGLayoutHints *laymenuitem = new TGLayoutHints(kLHintsTop|kLHintsLeft, 0, 4, 0, 0); 344 TGLayoutHints *laylinesep = new TGLayoutHints(kLHintsTop|kLHintsExpandX); 345 346 fList->Add(laymenubar); 347 fList->Add(laymenuitem); 348 fList->Add(laylinesep); 349 350 TGPopupMenu *filemenu = new TGPopupMenu(gClient->GetRoot()); 351 filemenu->AddEntry("Save &As...", kFileSaveAs); 352 filemenu->AddEntry("Save As display.&ps", kFileSaveAsPS); 353 filemenu->AddEntry("Save As display.&eps", kFileSaveAsEPS); 354 filemenu->AddEntry("Save As display.&gif", kFileSaveAsGIF); 355 filemenu->AddEntry("Save As display.&C", kFileSaveAsC); 356 filemenu->AddEntry("Save As display.&root", kFileSaveAsRoot); 357 filemenu->AddSeparator(); 358 filemenu->AddEntry("&Print...", kFilePrint); 359 filemenu->AddSeparator(); 360 filemenu->AddEntry("E&xit", kClose); 361 filemenu->Associate(this); 362 363 TGMenuBar *menubar = new TGMenuBar(this, 1, 1, kHorizontalFrame); 364 menubar->AddPopup("File", filemenu, laymenuitem); 365 AddFrame(menubar, laymenubar); 366 367 TGHorizontal3DLine *linesep = new TGHorizontal3DLine(this); 368 AddFrame(linesep, laylinesep); 369 370 fList->Add(filemenu); 371 fList->Add(menubar); 372 fList->Add(linesep); 373 } 374 332 375 MGEvtDisplay::MGEvtDisplay(const char *fname, const char *tname, 333 376 const TGWindow *p, const TGWindow *main, … … 346 389 // (via SetOwner()) 347 390 // 348 349 391 MTaskList *tlist = new MTaskList; 350 392 tlist->SetOwner(); … … 353 395 tlist->AddToList(read); 354 396 355 MParList *plist = new MParList ();397 MParList *plist = new MParList; 356 398 plist->SetOwner(); 357 399 plist->AddToList(tlist); … … 361 403 fEvtLoop->SetParList(plist); 362 404 363 // 364 // Add all GUI elements and update the event counter 365 // 405 AddMenuBar(); 366 406 AddFrames(fname, tname); 367 407 UpdateEventCounter(); 368 408 } 369 409 370 371 410 // -------------------------------------------------------------------------- 372 411 // … … 375 414 MGEvtDisplay::~MGEvtDisplay() 376 415 { 377 delete fList;378 379 416 fEvtLoop->PostProcess(); 380 417 delete fEvtLoop; 418 419 delete fList; 381 420 } 382 421 … … 404 443 Int_t retval = 0; 405 444 445 // 406 446 // first check if the new event is in the range of possible events 407 447 // 408 448 if (iEvt >= GetReader()->GetEntries()) 409 449 { 410 new TGMsgBox(gClient->GetRoot(), this, 411 "WARNING!", 450 new TGMsgBox(gClient->GetRoot(), this, "WARNING!", 412 451 "The event number is out of range!!!", 413 452 kMBIconExclamation, buttons, &retval); … … 435 474 436 475 fTxtEvtNr->SetText(txt); 476 } 477 478 // -------------------------------------------------------------------------- 479 // 480 // Opens a save as dialog, and tries to store the canvas 481 // in the given output format 482 // 483 void MGEvtDisplay::SaveAsDialog() const 484 { 485 static const char *gSaveAsTypes[] = 486 { 487 "PostScript", "*.ps", 488 "Encapsulated PostScript", "*.eps", 489 "Gif files", "*.gif", 490 "Macro files", "*.C", 491 "ROOT files", "*.root", 492 "All files", "*", 493 NULL, NULL 494 }; 495 496 static TString dir("."); 497 498 TGFileInfo fi; 499 500 fi.fFileTypes = gSaveAsTypes; 501 fi.fIniDir = StrDup(dir); 502 503 new TGFileDialog(fClient->GetRoot(), this, kFDSave, &fi); 504 505 if (!fi.fFilename) 506 return; 507 508 dir = fi.fIniDir; 509 510 if (strstr(fi.fFilename, ".root") || 511 strstr(fi.fFilename, ".ps") || 512 strstr(fi.fFilename, ".eps") || 513 strstr(fi.fFilename, ".gif")) 514 { 515 fCanvas->SaveAs(fi.fFilename); 516 return; 517 } 518 if (strstr(fi.fFilename, ".C")) 519 { 520 fCanvas->SaveSource(fi.fFilename); 521 return; 522 } 523 Warning("SaveAsDialog", "Unknown Extension: %s", fi.fFilename); 437 524 } 438 525 … … 456 543 switch (parm1) 457 544 { 458 case M_PREVEVT:545 case kEvtPrev: 459 546 // 460 547 // '-2' is because MReadTree::Process increases the … … 465 552 return kTRUE; 466 553 467 case M_NEXTEVT:554 case kEvtNext: 468 555 // 469 556 // '+0' is because MReadTree::Process increases the … … 474 561 return kTRUE; 475 562 476 case M_CLOSE: 563 case kClose: 564 CloseWindow(); 565 return kTRUE; 566 } 567 return kTRUE; 568 569 case kCM_MENU: 570 switch (parm1) 571 { 572 case kFileSaveAs: 573 SaveAsDialog(); 574 return kTRUE; 575 case kFileSaveAsRoot: 576 fCanvas->SaveAs("display.root"); 577 return kTRUE; 578 case kFileSaveAsC: 579 fCanvas->SaveSource("display.C"); 580 return kTRUE; 581 case kFileSaveAsPS: 582 fCanvas->SaveAs("display.ps"); 583 return kTRUE; 584 case kFileSaveAsEPS: 585 fCanvas->SaveAs("display.eps"); 586 return kTRUE; 587 case kFileSaveAsGIF: 588 fCanvas->SaveAs("display.gif"); 589 return kTRUE; 590 case kFilePrint: 591 fCanvas->Print(); 592 return kTRUE; 593 case kClose: 477 594 CloseWindow(); 478 595 return kTRUE; -
trunk/MagicSoft/Mars/meventdisp/MGEvtDisplay.h
r1015 r1023 29 29 TGTextEntry *fTxtEvtNr; 30 30 31 void AddMenuBar(); 31 32 void AddTopFramePart1(TGVerticalFrame *frame, 32 33 const char *filename, … … 37 38 38 39 void AddFrames(const char *filename, const char *treename); 40 41 void SaveAsDialog() const; 39 42 40 43 void ReadinEvent(UInt_t iEvt); -
trunk/MagicSoft/Mars/mgui/MCamDisplay.cc
r1018 r1023 2 2 3 3 #include <math.h> 4 #include <fstream.h> 4 5 5 6 #include <TClonesArray.h> … … 308 309 } 309 310 } 311 312 // ------------------------------------------------------------------------ 313 // 314 // Save primitive as a C++ statement(s) on output stream out 315 // 316 void MCamDisplay::SavePrimitive(ofstream &out, Option_t *opt) 317 { 318 if (!gROOT->ClassSaved(TCanvas::Class())) 319 fDrawingPad->SavePrimitive(out, opt); 320 321 out << " " << fDrawingPad->GetName() << "->SetWindowSize("; 322 out << fDrawingPad->GetWw() << "," << fDrawingPad->GetWh() << ");" << endl; 323 } -
trunk/MagicSoft/Mars/mgui/MCamDisplay.h
r1015 r1023 57 57 void Reset(); 58 58 void Draw(Option_t *option=""); 59 void SavePrimitive(ofstream &out, Option_t *); 59 60 60 61 ClassDef(MCamDisplay, 0) // Displays the magic camera -
trunk/MagicSoft/Mars/mgui/MHexagon.cc
r1018 r1023 30 30 #include "MHexagon.h" 31 31 32 #include <fstream.h> 32 33 #include <iostream.h> 33 34 … … 51 52 // 52 53 MHexagon::MHexagon(Float_t x, Float_t y, Float_t d) 53 : TAtt Fill(0, 1001), fX(x), fY(y), fD(d)54 : TAttLine(1, 1, 1), TAttFill(0, 1001), fX(x), fY(y), fD(d) 54 55 { 55 56 } … … 60 61 // 61 62 MHexagon::MHexagon(MGeomPix &pix) 62 : TAtt Fill(0, 1001)63 : TAttLine(1, 1, 1), TAttFill(0, 1001) 63 64 { 64 65 fX = pix.GetX(); … … 246 247 void MHexagon::Print(Option_t *) const 247 248 { 248 cout << GetName() << ": x=" << fX << "mm y=" << fY << "mm r=" << fD << "mm" << endl; 249 250 cout << " Color=" << GetLineColor() << ","; 251 cout << " Style=" << GetLineStyle() << ","; 252 cout << " Width=" << GetLineWidth() << ","; 253 cout << " FillColor=" << GetFillColor() << endl; 254 } 249 cout << "MHexagon - " << GetName() << ": "; 250 cout << "x=" << fX << "mm y=" << fY << "mm r=" << fD << "mm" << endl; 251 252 cout << " Line:"; 253 cout << " Color=" << GetLineColor() << ","; 254 cout << " Style=" << GetLineStyle() << ","; 255 cout << " Width=" << GetLineWidth() << endl; 256 cout << " Fill:"; 257 cout << " Color=" << GetFillColor() << ","; 258 cout << " Style=" << GetFillStyle() << endl; 259 } 260 261 // ------------------------------------------------------------------------ 262 // 263 // Save primitive as a C++ statement(s) on output stream out 264 // 265 void MHexagon::SavePrimitive(ofstream &out, Option_t *) 266 { 267 268 if (gROOT->ClassSaved(MHexagon::Class())) 269 out << " "; 270 else 271 out << " MHexagon *"; 272 273 out << "hexagon = new MHexagon(" << fX << "," << fY << "," << fD << ");" << endl; 274 275 SaveFillAttributes(out, "hexagon"); 276 SaveLineAttributes(out, "hexagon"); 277 278 out << " hexagon->Draw();" << endl; 279 } -
trunk/MagicSoft/Mars/mgui/MHexagon.h
r1018 r1023 44 44 virtual ~MHexagon(); 45 45 46 v oid Copy(TObject &hexagon);46 virtual void Copy(TObject &hexagon); 47 47 48 48 virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); 49 virtual void DrawHexagon( 49 virtual void DrawHexagon(Float_t x, Float_t y, Float_t d); 50 50 51 51 //virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py); … … 55 55 virtual void PaintHexagon(Float_t x, Float_t y, Float_t d); 56 56 virtual void Print(Option_t *Option="") const; // *MENU* 57 virtual void SavePrimitive(ofstream &out, Option_t *); 57 58 58 59 ClassDef(MHexagon, 0) // A hexagon for MAGIC -
trunk/MagicSoft/Mars/mhist/MHHillas.cc
r1004 r1023 36 36 // connect all the histogram with the container fHist 37 37 // 38 fAlpha = new TH1F("Alpha [ deg]", "Alpha of Hillas", 90, 0, 90);38 fAlpha = new TH1F("Alpha [°]", "Alpha of Hillas", 90, 0, 90); 39 39 fWidth = new TH1F("Width [mm]", "Width of Hillas", 100, 0, 300); 40 40 fLength = new TH1F("Length [mm]", "Length of Hillas", 100, 0, 300); … … 46 46 fWidth->SetDirectory(NULL); 47 47 48 fAlpha->GetXaxis()->SetTitle("Alpha [ deg]");48 fAlpha->GetXaxis()->SetTitle("Alpha [°]"); 49 49 fLength->GetXaxis()->SetTitle("Length [mm]"); 50 50 fDist->GetXaxis()->SetTitle("Dist [mm]"); -
trunk/MagicSoft/Mars/mmain/MDataCheck.cc
r959 r1023 28 28 #include <TGButton.h> // TGTextButton 29 29 30 // ---31 32 30 #include "MParList.h" 33 31 #include "MTaskList.h" … … 42 40 43 41 enum { 44 M_BUTTON_PEDADC,45 M_BUTTON_CRADC,46 M_BUTTON_PEDTDC,47 M_BUTTON_CRTDC42 kButPedAdc, 43 kButEvtAdc, 44 kButPedTdc, 45 kButEvtTdc 48 46 }; 49 47 … … 58 56 : MBrowser(main, p, w, h) 59 57 { 60 TGTextButton *pedadc = new TGTextButton(fTop2, "ADC Spectra of Pedestals", M_BUTTON_PEDADC);61 TGTextButton *cradc = new TGTextButton(fTop2, "ADC Specta of Cosmics", M_BUTTON_CRADC);62 TGTextButton *pedtdc = new TGTextButton(fTop3, "TDC Spectra of Pedestals", M_BUTTON_PEDTDC);63 TGTextButton *crtdc = new TGTextButton(fTop3, "TDC Specta of Cosmics", M_BUTTON_CRTDC);58 TGTextButton *pedadc = new TGTextButton(fTop2, "ADC Spectra of Pedestals", kButPedAdc); 59 TGTextButton *cradc = new TGTextButton(fTop2, "ADC Specta of Cosmics", kButEvtAdc); 60 TGTextButton *pedtdc = new TGTextButton(fTop3, "TDC Spectra of Pedestals", kButPedTdc); 61 TGTextButton *crtdc = new TGTextButton(fTop3, "TDC Specta of Cosmics", kButEvtTdc); 64 62 65 63 pedadc->Associate(this); … … 129 127 magic.SetParList(&plist); 130 128 129 // ADD ProgressBar, TGHProgressBar::ShowStatus(); 130 131 131 // 132 132 // start the loop running … … 151 151 switch (parm1) 152 152 { 153 case M_BUTTON_PEDADC:154 case M_BUTTON_CRADC:155 case M_BUTTON_PEDTDC:156 case M_BUTTON_CRTDC:153 case kButPedAdc: 154 case kButEvtAdc: 155 case kButPedTdc: 156 case kButEvtTdc: 157 157 if (!InputFileSelected()) 158 158 { … … 163 163 switch (parm1) 164 164 { 165 case M_BUTTON_PEDADC:165 case kButPedAdc: 166 166 ViewAdcSpectra(fInputFile, "PedEvents"); 167 167 return kTRUE; 168 168 169 case M_BUTTON_CRADC:169 case kButEvtAdc: 170 170 ViewAdcSpectra(fInputFile, "Events"); 171 171 return kTRUE; 172 172 173 case M_BUTTON_PEDTDC:173 case kButPedTdc: 174 174 // fOctober.PedTdcSpectra(fInputFile) ; 175 175 return kTRUE; 176 176 177 case M_BUTTON_CRTDC:177 case kButEvtTdc: 178 178 return kTRUE; 179 179 }
Note:
See TracChangeset
for help on using the changeset viewer.