GSI Object Oriented Online Offline (Go4) GO4-6.4.0
Loading...
Searching...
No Matches
TGo4DrawObjProxy.cxx
Go to the documentation of this file.
1// $Id$
2//-----------------------------------------------------------------------
3// The GSI Online Offline Object Oriented (Go4) Project
4// Experiment Data Processing at EE department, GSI
5//-----------------------------------------------------------------------
6// Copyright (C) 2000- GSI Helmholtzzentrum fuer Schwerionenforschung GmbH
7// Planckstr. 1, 64291 Darmstadt, Germany
8// Contact: http://go4.gsi.de
9//-----------------------------------------------------------------------
10// This software can be used under the license agreements as stated
11// in Go4License.txt file which is part of the distribution.
12//-----------------------------------------------------------------------
13
14#include "TGo4DrawObjProxy.h"
15
16#include "TList.h"
17#include "THStack.h"
18#include "TMultiGraph.h"
19
20TGo4DrawObjProxy::TGo4DrawObjProxy(TObject *obj, Bool_t owner, Bool_t doclear) :
21 TGo4ObjectProxy(obj, owner),
22 fDoClear(doclear)
23{
24}
25
30
36
38{
39 if (!fObject) return;
40 if (fObject->InheritsFrom(THStack::Class())) {
41 THStack *hs = (THStack*) fObject;
42 if (hs->GetHists())
43 hs->GetHists()->Clear();
44 } else if (fObject->InheritsFrom(TMultiGraph::Class())) {
45 TMultiGraph *mgr = (TMultiGraph *) fObject;
46 if (mgr->GetListOfGraphs())
47 mgr->GetListOfGraphs()->Clear();
48 }
49}
Bool_t RemoveRegisteredObject(TObject *obj) override
TGo4DrawObjProxy(TObject *obj, Bool_t owner, Bool_t doclear=kFALSE)
Bool_t RemoveRegisteredObject(TObject *obj) override