Changeset 9410


Ignore:
Timestamp:
03/23/09 13:14:46 (16 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r9409 r9410  
    2222   * resources/starguider01000534.txt:
    2323     - added
     24
     25   * mbase/MStatusDisplay.cc:
     26     - if no MStatusArray is found now all object are drawn
     27
     28   * mfileio/MWriteRootFile.[h,cc]:
     29     - trees to be copied can now be made optional
     30
     31   * mhbase/MH.cc:
     32     - included TProfile2D for newer root versions
    2433
    2534
  • trunk/MagicSoft/Mars/NEWS

    r9402 r9410  
    22
    33== <cvs> ==
     4
     5 ;showplot:
     6
     7   * If a file without a MStatusArray is opened all object (not just
     8     canvases) found in the file are drawn. Note that this may result
     9     in empty tabs.
    410
    511 ;ganymed:
  • trunk/MagicSoft/Mars/mbase/MStatusDisplay.cc

    r9369 r9410  
    23222322            gFile->GetObject(key->GetName(), c);
    23232323            if (!c)
    2324                 break;
     2324            {
     2325                AddTab(key->GetName(), key->GetTitle());
     2326                TObject *obj = gFile->Get(key->GetName());
     2327                obj->SetBit(kCanDelete);
     2328                obj->Draw();
     2329                continue;
     2330            }
    23252331
    23262332            if (list.GetEntries()==0)
  • trunk/MagicSoft/Mars/mfileio/MWriteRootFile.cc

    r9343 r9410  
    458458// completely from one file to another one you can use this
    459459//
    460 void MWriteRootFile::AddCopySource(const char *tname, const char *bname)
    461 {
    462     fCopies.Add(new TNamed(tname, bname?bname:"*"));
     460void MWriteRootFile::AddCopySource(const char *tname, const char *bname, Bool_t force)
     461{
     462    TObject *obj = new TNamed(tname, bname?bname:"*");
     463    if (force)
     464        obj->SetBit(kForced);
     465
     466    fCopies.Add(obj);
    463467    fCopies.Sort();
    464468}
     
    980984        if (!gettree)
    981985        {
    982             *fLog << err << "ERROR - MakeCopies: Tree " << o->GetName() << " not found in file " << fname << "... abort." << endl;
    983             return kFALSE;
     986            const Bool_t force = o->TestBit(kForced);
     987            if (force)
     988                *fLog << err << "ERROR - ";
     989            else
     990                *fLog << inf3;
     991
     992            *fLog << "MakeCopies: Tree " << o->GetName() << " not found in file " << fname << ".";
     993            if (force)
     994                *fLog << ".. abort.";
     995            *fLog << endl;
     996
     997            if (force)
     998                return kFALSE;
     999
     1000            continue;
    9841001        }
    9851002
  • trunk/MagicSoft/Mars/mfileio/MWriteRootFile.h

    r9328 r9410  
    8585        kIsNotOwner = BIT(14), // MWriteRootFile is not owner of fOut
    8686        kFillTree   = BIT(14),
     87        kForced     = BIT(14), // Used for flag in fCopies
    8788        // Be carefull these bits are already in use!
    8889        // TBranch::kAutoDelete = BIT(15)
     
    130131    void AddContainer(const char *cname,   const char *tname=NULL, Bool_t must=kTRUE);
    131132    void AddContainer(MParContainer *cont, const char *tname=NULL, Bool_t must=kTRUE);
    132     void AddCopySource(const char *tname, const char *bname=NULL);
     133    void AddCopySource(const char *tname, const char *bname=NULL, Bool_t force=kTRUE);
     134    void AddCopySource(const char *tname, Bool_t force)
     135    {
     136        AddCopySource(tname, NULL, force);
     137    }
    133138
    134139    void AddTree(const char *name, Bool_t force=kTRUE)
  • trunk/MagicSoft/Mars/mhbase/MH.cc

    r9369 r9410  
    11/* ======================================================================== *\
    2 ! $Name: not supported by cvs2svn $:$Id: MH.cc,v 1.47 2009-03-01 21:48:14 tbretz Exp $
     2! $Name: not supported by cvs2svn $:$Id: MH.cc,v 1.48 2009-03-23 13:13:42 tbretz Exp $
    33! --------------------------------------------------------------------------
    44!
     
    7070#include <THLimitsFinder.h>
    7171#endif
     72#include <TProfile2D.h>  // root > 5.18
    7273
    7374#include "MLog.h"
  • trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc

    r9334 r9410  
    760760    writemc.AddContainer("MMcEvtBasic", "OriginalMC", kFALSE);
    761761    if (fSequence.IsMonteCarlo())
    762         writemc.AddCopySource("OriginalMC");
     762        writemc.AddCopySource("OriginalMC", kFALSE);
    763763
    764764    // Write the special calib tree
Note: See TracChangeset for help on using the changeset viewer.