Changeset 8727 for trunk


Ignore:
Timestamp:
09/03/07 10:37:51 (17 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mbase/MEnv.cc

    r8716 r8727  
    4141// some of the resources.
    4242//
     43// If given paths are not absolute there base is always th elocation of
     44// the including file.
     45//
    4346//////////////////////////////////////////////////////////////////////////////
    4447#include "MEnv.h"
     
    111114        return 0;
    112115
     116    const char *dir = gSystem->DirName(GetRcName());
     117
    113118    // Tokenize the array into single files divided by a whitespace
    114119    TObjArray *arr = incl.Tokenize(" ");
     
    123128    {
    124129        // Get file name to include
    125         const char *fenv = (*arr)[i]->GetName();
     130        TString fenv = (*arr)[i]->GetName();
     131
     132        // If the is not anabsolute path we prepend the dir-name
     133        // of the including file. This allows that includes
     134        // do not necessarily need absolute paths and paths are always
     135        // relative to the location of th eincluding file.
     136        if (!gSystem->IsAbsoluteFileName(fenv))
     137        {
     138            fenv.Prepend("/");
     139            fenv.Prepend(dir);
     140        }
    126141
    127142        // Read included file and check if its valid
  • trunk/MagicSoft/Mars/mjobs/MJSpectrum.cc

    r8719 r8727  
    15201520    SetupHistEnergyEst(heest);
    15211521
    1522     //MHn hdisp("Disp", "Dist residual (Disp-Dist)");
    1523     //SetupHistDisp(hdisp);
     1522    MHn hdisp("Disp", "Dist residual (Disp-Dist)");
     1523    SetupHistDisp(hdisp);
    15241524
    15251525    MHn henergy("EvtDist");
     
    15291529    fill4b.SetWeight();
    15301530
    1531     //MFillH fill4c(&hdisp, "", "FillDispResidual");
    1532     //fill4c.SetWeight();
     1531    MFillH fill4c(&hdisp, "", "FillDispResidual");
     1532    fill4c.SetWeight();
     1533
     1534    MFDataPhrase fdisp("Disp.fVal*sign(MHillasSrc.fCosDeltaAlpha)<0", "FilterDisp");
     1535    fill4c.SetFilter(&fdisp);
    15331536
    15341537    // ---------------------------------------------------------
     
    16001603    tlist2.AddToList(&taskenv0);
    16011604    tlist2.AddToList(&taskenv1);
     1605    tlist2.AddToList(&fdisp);
     1606    tlist2.AddToList(&fill4c);
    16021607    tlist2.AddToList(fCut1);
    16031608    tlist2.AddToList(fCutS);
Note: See TracChangeset for help on using the changeset viewer.