Docker-in-Docker (DinD) capabilities of public runners deactivated. More info

Commit 58f2e6c7 authored by Jérémie Dudouet's avatar Jérémie Dudouet
Browse files

Merge branch 'Cubix' into 'Cubix'

correct a bug in cleaning peak search

See merge request !41
parents 8d7510fa a6a3ac64
Pipeline #38411 passed with stage
in 4 minutes and 54 seconds
...@@ -90,7 +90,7 @@ void CXArrow::SetText(TH1 *hist, TString text, TString tooltip) ...@@ -90,7 +90,7 @@ void CXArrow::SetText(TH1 *hist, TString text, TString tooltip)
hist->GetYaxis()->SetRangeUser(gPad->GetUymin(),Y+MaxGlob/50.); hist->GetYaxis()->SetRangeUser(gPad->GetUymin(),Y+MaxGlob/50.);
} }
void CXArrow::ClearPad(TVirtualPad *pad) void CXArrow::ClearPad(TVirtualPad *pad, bool refresh)
{ {
if(pad==nullptr) pad = gPad; if(pad==nullptr) pad = gPad;
...@@ -98,8 +98,10 @@ void CXArrow::ClearPad(TVirtualPad *pad) ...@@ -98,8 +98,10 @@ void CXArrow::ClearPad(TVirtualPad *pad)
pad->GetListOfPrimitives()->Remove(fBox); pad->GetListOfPrimitives()->Remove(fBox);
pad->GetListOfPrimitives()->Remove(this); pad->GetListOfPrimitives()->Remove(this);
pad->Modified(); if(refresh) {
pad->Update(); pad->Modified();
pad->Update();
}
} }
......
...@@ -43,7 +43,7 @@ public: ...@@ -43,7 +43,7 @@ public:
void SetText(TH1 *hist, TString text, TString tooltip); void SetText(TH1 *hist, TString text, TString tooltip);
void ClearPad(TVirtualPad *pad = nullptr); void ClearPad(TVirtualPad *pad = nullptr, bool refresh = true);
virtual void Paint(Option_t *option = ""); virtual void Paint(Option_t *option = "");
......
...@@ -212,6 +212,7 @@ void CXHist1DPlayer::SetMainWindow(CXMainWindow *w) ...@@ -212,6 +212,7 @@ void CXHist1DPlayer::SetMainWindow(CXMainWindow *w)
void CXHist1DPlayer::PeakSearchClear() void CXHist1DPlayer::PeakSearchClear()
{ {
TVirtualPad *pad = fMainWindow->GetSelectedPad(); TVirtualPad *pad = fMainWindow->GetSelectedPad();
gPad = pad;
if(pad==nullptr) { if(pad==nullptr) {
cout<<"No selected pad, ignored"<<endl; cout<<"No selected pad, ignored"<<endl;
...@@ -221,7 +222,7 @@ void CXHist1DPlayer::PeakSearchClear() ...@@ -221,7 +222,7 @@ void CXHist1DPlayer::PeakSearchClear()
for(int i=0 ; i<pad->GetListOfPrimitives()->GetEntries() ; i++) { for(int i=0 ; i<pad->GetListOfPrimitives()->GetEntries() ; i++) {
TObject *o = pad->GetListOfPrimitives()->At(i); TObject *o = pad->GetListOfPrimitives()->At(i);
if(o->InheritsFrom(CXArrow::Class())) { if(o->InheritsFrom(CXArrow::Class())) {
((CXArrow*)o)->ClearPad(); ((CXArrow*)o)->ClearPad(pad,false);
i--; i--;
} }
} }
......
...@@ -71,6 +71,9 @@ CXLevelSchemePlayer::CXLevelSchemePlayer(const char* name, const char *title) : ...@@ -71,6 +71,9 @@ CXLevelSchemePlayer::CXLevelSchemePlayer(const char* name, const char *title) :
fListOfBoxes = new TList; fListOfBoxes = new TList;
fListOfBoxes->SetOwner(); fListOfBoxes->SetOwner();
fListOfCXArrows = new TList;
fListOfCXArrows->SetOwner();
} }
CXLevelSchemePlayer::~CXLevelSchemePlayer() CXLevelSchemePlayer::~CXLevelSchemePlayer()
...@@ -80,9 +83,9 @@ CXLevelSchemePlayer::~CXLevelSchemePlayer() ...@@ -80,9 +83,9 @@ CXLevelSchemePlayer::~CXLevelSchemePlayer()
void CXLevelSchemePlayer::ConnectCanvas() void CXLevelSchemePlayer::ConnectCanvas()
{ {
TList *l = fMainWindow->GetCanvas()->GetListOfSignals(); // TList *l = fMainWindow->GetCanvas()->GetListOfSignals();
if(l==nullptr || l->FindObject("ProcessedEventLevelScheme(int,int,int,TObject*)") == nullptr) // if(l==nullptr || l->FindObject("ProcessedEventLevelScheme(int,int,int,TObject*)") == nullptr)
fMainWindow->GetCanvas()->Connect("ProcessedEvent(Int_t, Int_t, Int_t, TObject*)","CXLevelSchemePlayer", this, "ProcessedEventLevelScheme(Int_t, Int_t, Int_t, TObject*)"); fMainWindow->GetCanvas()->Connect("ProcessedEvent(Int_t, Int_t, Int_t, TObject*)","CXLevelSchemePlayer", this, "ProcessedEventLevelScheme(Int_t, Int_t, Int_t, TObject*)");
} }
void CXLevelSchemePlayer::DrawArrows(TString ListOfNuclei,TH1 *h) void CXLevelSchemePlayer::DrawArrows(TString ListOfNuclei,TH1 *h)
...@@ -116,22 +119,6 @@ void CXLevelSchemePlayer::DrawArrows(TString ListOfNuclei,TH1 *h) ...@@ -116,22 +119,6 @@ void CXLevelSchemePlayer::DrawArrows(TString ListOfNuclei,TH1 *h)
} }
} }
// if(fListOfArrows != nullptr)
// delete fListOfArrows;
// if(fListOfLatex != nullptr)
// delete fListOfLatex;
// if(fListOfBoxes != nullptr)
// delete fListOfBoxes;
// fListOfArrows = new TList;
// fListOfArrows->SetOwner();
// fListOfLatex = new TList;
// fListOfLatex->SetOwner();
// fListOfBoxes = new TList;
// fListOfBoxes->SetOwner();
fCurrentHist = h; fCurrentHist = h;
fCurrentHist->GetYaxis()->UnZoom(); fCurrentHist->GetYaxis()->UnZoom();
......
...@@ -56,6 +56,7 @@ private: ...@@ -56,6 +56,7 @@ private:
TList *fListOfArrows = nullptr; TList *fListOfArrows = nullptr;
TList *fListOfLatex = nullptr; TList *fListOfLatex = nullptr;
TList *fListOfBoxes = nullptr; TList *fListOfBoxes = nullptr;
TList *fListOfCXArrows = nullptr;
TList *fListOfDatabase = nullptr; TList *fListOfDatabase = nullptr;
......
...@@ -20,6 +20,13 @@ private: ...@@ -20,6 +20,13 @@ private:
Float_t fLifeTime; Float_t fLifeTime;
TString fJPi;
TString fJDecay;
Float_t MassExc;
Float_t Abund;
Float_t Branching;
NucData *fdata; NucData *fdata;
public: public:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment