| 218 |
// |
// |
| 219 |
// check if we have an input filename |
// check if we have an input filename |
| 220 |
// |
// |
| 221 |
if ( filename.Data() == "" || !strcmp(filename.Data(),"help") ){ |
// if ( filename.Data() == "" || !strcmp(filename.Data(),"help") ){ |
| 222 |
|
if ( !strcmp(gSystem->BaseName(filename),"") || filename.Contains("help") ){ |
| 223 |
pamela->var.waitforever = true; |
pamela->var.waitforever = true; |
| 224 |
}; |
}; |
| 225 |
// // |
// // |
| 290 |
// |
// |
| 291 |
if ( firsttime ){ |
if ( firsttime ){ |
| 292 |
firsttime = false; |
firsttime = false; |
| 293 |
if ( filename == "" ) pamgui->DIALOG(0," Insert the filename and press load to start "); |
if ( !strcmp(gSystem->BaseName(filename),"") || filename.Contains("help") ) pamgui->DIALOG(3," - Insert the filename and press load to start \n - To unload selection file clean the line and press the \"Load\" button \n - run with \"-v\" option to have STDOUT on the screen \n - select a detector and press \"Show Data\" to print data event by event on the screen "); |
| 294 |
|
// if ( filename.Contains("help") ) pamgui->DIALOG(3," - Insert the filename and press load to start \n - To unload selection file clean the line and press the \"Load\" button \n - run with \"-v\" option to have STDOUT on the screen \n - select a detector and press \"Show Data\" to print data event by event on the screen "); |
| 295 |
|
// printf(" - %s - %s =\n",gSystem->BaseName(filename),filename.Data()); |
| 296 |
}; |
}; |
| 297 |
// |
// |
| 298 |
// WAIT for an input filename |
// WAIT for an input filename |
| 301 |
if ( !gROOT->GetListOfCanvases()->FindObject(figure) ) { |
if ( !gROOT->GetListOfCanvases()->FindObject(figure) ) { |
| 302 |
pamgui->Terminate(); |
pamgui->Terminate(); |
| 303 |
}; |
}; |
| 304 |
|
pamgui->Refresh(); |
| 305 |
gSystem->ProcessEvents(); |
gSystem->ProcessEvents(); |
| 306 |
gSystem->Sleep(10); |
gSystem->Sleep(10); |
| 307 |
}; |
}; |
| 323 |
// |
// |
| 324 |
// LOAD SELECTION FILE |
// LOAD SELECTION FILE |
| 325 |
// |
// |
| 326 |
if ( selfile == "" ){ |
if ( !strcmp(gSystem->BaseName(selfile),"") ){ //selfile == "" ){ |
| 327 |
//if ( !pamela->var.selex ) pamgui->DIALOG(0," Selection file unloaded "); |
//if ( !pamela->var.selex ) pamgui->DIALOG(0," Selection file unloaded "); |
| 328 |
if ( pamela->var.selex ) pamgui->DIALOG(0," Selection file unloaded "); |
if ( pamela->var.selex ) pamgui->DIALOG(0," Selection file unloaded "); |
| 329 |
pamela->var.selex = false; |
pamela->var.selex = false; |
| 387 |
// LOAD FILES |
// LOAD FILES |
| 388 |
// |
// |
| 389 |
// |
// |
| 390 |
// if ( headerFile ) headerFile->Close(); |
// if ( headerFile ) headerFile->Close(); |
| 391 |
// if ( otr ) otr->Delete(); |
// if ( otr ) otr->Delete(); |
| 392 |
// if ( L0 ) L0->Delete(); |
// if ( L0 ) L0->Delete(); |
| 393 |
|
|
| 394 |
// |
// |
| 395 |
// check if user has given as input a correct path |
// check if user has given as input a correct path |
| 672 |
// |
// |
| 673 |
pamela->var.goon = false; |
pamela->var.goon = false; |
| 674 |
if ( pamela->var.refresh || pamela->var.restart ){ |
if ( pamela->var.refresh || pamela->var.restart ){ |
| 675 |
|
// printf(" qua \n"); |
| 676 |
|
if ( pamela->GetL2() ) pamela->GetL2()->Clear(); |
| 677 |
if ( pamela->GetL2() ) pamela->GetL2()->Reset(); |
if ( pamela->GetL2() ) pamela->GetL2()->Reset(); |
| 678 |
|
if ( pamela->GetL2() ) pamela->GetL2()->Delete(); |
| 679 |
|
pamela->Reset(); |
| 680 |
if ( pamela->level.file != 2 ) pamela->GetChain()->Delete(); |
if ( pamela->level.file != 2 ) pamela->GetChain()->Delete(); |
| 681 |
otr = NULL; |
otr = NULL; |
| 682 |
// if ( headerFile ) headerFile->Close("R"); |
// if ( headerFile ) headerFile->Close("R"); |
| 683 |
|
// if ( pamela->var.refresh ){ |
| 684 |
|
// pamela->var.refresh = false; |
| 685 |
|
// pamela->var.restart = true; |
| 686 |
|
// }; |
| 687 |
if ( pamela->var.refresh ) goto refresh; |
if ( pamela->var.refresh ) goto refresh; |
| 688 |
if ( pamela->var.restart ){ |
if ( pamela->var.restart ){ |
| 689 |
|
// if ( pamela->GetL2() ) pamela->GetL2()->Reset(); |
| 690 |
|
// pamela->Reset(); |
| 691 |
|
// if ( pamela->level.file != 2 ) pamela->GetChain()->Delete(); |
| 692 |
|
// otr = NULL; |
| 693 |
i = pamela->var.i; |
i = pamela->var.i; |
| 694 |
filename = pamela->var.thefilename.Data(); |
filename = pamela->var.thefilename.Data(); |
| 695 |
goto restart; |
goto restart; |
| 696 |
}; |
}; |
| 697 |
}; |
}; |
| 698 |
// |
// |
| 699 |
|
// printf(" que %i \n",i); |
| 700 |
|
// if ( i < 0 ) i = 0; // boh |
| 701 |
i = pamela->var.i; |
i = pamela->var.i; |
| 702 |
if ( i != pamela->si ) pamela->OOBT = 1000000000; |
if ( i != pamela->si ) pamela->OOBT = 1000000000; |
| 703 |
if ( pamela->maxevent < i ) { |
if ( pamela->maxevent < i ) { |