Index: trunk/MagicSoft/Mars/Changelog
===================================================================
--- trunk/MagicSoft/Mars/Changelog	(revision 9037)
+++ trunk/MagicSoft/Mars/Changelog	(revision 9038)
@@ -18,4 +18,28 @@
 
                                                  -*-*- END OF LINE -*-*-
+
+ 2008/07/23 Thomas Bretz
+
+   * showplot.cc:
+     - allow to read more than one file
+
+   * datacenter/macros/stage.C:
+     - chnaged the return type to int
+
+   * mbase/MStatusArray.cc:
+     - added a check for the key in read to supress the root error
+       on the console
+
+   * mbase/MStatusDisplay.[h,cc]:
+     - stop update timer in destructor
+     - added new member function GetNumTabs
+     - we don't need to switch to batchmore when painting canvases
+       anymore
+     - removed an obsolete cout
+
+   * mjobs/MJCalibrateSignal.cc:
+     - changed again the wrong names of the tasklists
+
+
 
  2008/07/22 Thomas Bretz
@@ -98,4 +122,9 @@
      - small change to log-level
 
+   * mbase/MTaskList.cc:
+     - in case of an unknown return value stop event loop
+
+   * mfileio/MRead.cc:
+     - use gSystem->BaseName to get file name
 
 
Index: trunk/MagicSoft/Mars/NEWS
===================================================================
--- trunk/MagicSoft/Mars/NEWS	(revision 9037)
+++ trunk/MagicSoft/Mars/NEWS	(revision 9038)
@@ -26,4 +26,9 @@
    * MReadTree can now read also files not written by MARS and store
      the data encapsulated in emulated MParContainers
+
+ ;showplot
+
+   * showplot can now read more than one file at once. This is especially
+     inetersting if reading files containing pure canvases
 
  ;merpp
Index: trunk/MagicSoft/Mars/datacenter/macros/stage.C
===================================================================
--- trunk/MagicSoft/Mars/datacenter/macros/stage.C	(revision 9037)
+++ trunk/MagicSoft/Mars/datacenter/macros/stage.C	(revision 9038)
@@ -29,5 +29,5 @@
 }
 
-void stage(Int_t sequno, Int_t tel, TString path="")
+int stage(Int_t sequno, Int_t tel, TString path="")
 {
     const MSequenceSQL s("sql.rc", sequno, tel);
@@ -40,5 +40,5 @@
 }
 
-void stage(const char *seq, TString path="")
+int stage(const char *seq, TString path="")
 {
     const MSequence s(seq);
Index: trunk/MagicSoft/Mars/mbase/MStatusDisplay.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MStatusDisplay.cc	(revision 9037)
+++ trunk/MagicSoft/Mars/mbase/MStatusDisplay.cc	(revision 9038)
@@ -780,4 +780,6 @@
 MStatusDisplay::~MStatusDisplay()
 {
+    fTimer.Stop();
+
 #if ROOT_VERSION_CODE < ROOT_VERSION(3,10,01)
     fTab = NULL; // See HandleEvent
@@ -959,4 +961,14 @@
     c->cd();
     return kTRUE;
+}
+
+// --------------------------------------------------------------------------
+//
+// Return the number of user added tabs (not that in batch mode this
+// exclude tabs without a canvas)
+//
+Int_t MStatusDisplay::GetNumTabs() const
+{
+    return gROOT->IsBatch() ? fBatch->GetEntries() : fTab->GetNumberOfTabs()-1;
 }
 
@@ -2249,6 +2261,4 @@
 
 
-    cout << "Display done." << endl;
-
     if (n==0)
         return list.GetEntries();
@@ -2683,16 +2693,12 @@
         // deletion
         //
-        const Bool_t store = c->IsBatch();
-
-        c->SetBatch(kTRUE);
+        //const Bool_t store = c->IsBatch();
+        //c->SetBatch(kTRUE);
         c->Paint();
-        c->SetBatch(store);
+        //c->SetBatch(store);
 
         //
         // Use the canvas as coordinate system for the overlaying text
         //
-        gPad = c;
-        //n->cd();
-
         const Double_t height = 0.015;
 
Index: trunk/MagicSoft/Mars/mbase/MStatusDisplay.h
===================================================================
--- trunk/MagicSoft/Mars/mbase/MStatusDisplay.h	(revision 9037)
+++ trunk/MagicSoft/Mars/mbase/MStatusDisplay.h	(revision 9038)
@@ -196,4 +196,6 @@
      TObject *FindObject(const TObject *) const { return 0;  }
 
+     Int_t GetNumTabs() const;
+
      void PrintContent(Option_t *o="") const;
 
Index: trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc
===================================================================
--- trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc	(revision 9037)
+++ trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc	(revision 9038)
@@ -759,5 +759,5 @@
     // Build tasklist
 
-    MTaskList tlist2("PedEvents");
+    MTaskList tlist2("AllEvents");
 
     tlist2.AddToList(&caldec);
@@ -771,5 +771,5 @@
     // Pedestal extraction
 
-    MTaskList tlist3("CalEvents");
+    MTaskList tlist3("PedEvents");
     tlist3.SetFilter(&fped);         // Deny events with cal-trigger
 
@@ -786,5 +786,5 @@
     // Calibration
 
-    MTaskList tlist4;
+    MTaskList tlist4("CalEvents");
     tlist4.SetFilter(&fcalib);       // process only events with cal-trigger
 
Index: trunk/MagicSoft/Mars/showplot.cc
===================================================================
--- trunk/MagicSoft/Mars/showplot.cc	(revision 9037)
+++ trunk/MagicSoft/Mars/showplot.cc	(revision 9038)
@@ -19,5 +19,5 @@
     gLog << endl;
     gLog << "showplot --- Mars V" << MARSVER << " compiled on <" << __DATE__ << "> using ROOT v" << ROOT_RELEASE << endl;
-    gLog << endl;
+    //gLog << endl;
 }
 
@@ -28,7 +28,9 @@
     gLog << all << endl;
     gLog << "Sorry the usage is:" << endl;
-    gLog << " showplot [options] {filename}|{filetype number}" << endl << endl;
+    gLog << " showplot [options]" << endl;
+    gLog << " showplot [options] file1 file2 file3 ..." << endl;
+    gLog << " showplot [options] filetype number" << endl << endl;
     gLog << " Arguments:" << endl;
-    gLog << "   filename                  Input file containing an MStatusArray" << endl;
+    gLog << "   fil1 file2 ...            Input files containing an MStatusArray of TCanvases" << endl;
     gLog << "   filetype number           Open file of filetype calib, signal, star, etc." << endl;
     gLog << "                             of sequence or dataset number" << endl << endl;
@@ -100,11 +102,14 @@
     // Something special for datacenter access
     //
-    if (args.GetNumArguments()!=2)
+    if (args.GetNumArguments()==1)
         return kInput;
 
+    if (args.GetNumArguments()!=2 || !args.GetArgumentStr(1).IsDigit())
+        return "";
+
     //
     // Something special for datacenter access
     //
-    const Int_t num = args.GetArgumentStr(1).Atoi();
+    const Int_t num = args.GetArgumentInt(1);
 
     TString file = "/magic/data/";
@@ -191,24 +196,12 @@
 
     //
-    // check arguments before processing them in InflatePath
-    //
-    if (arg.GetNumArguments()<1 || arg.GetNumArguments()>2)
-    {
-        gLog << warn << "WARNING - Wrong number of arguments..." << endl;
-        Usage();
-        return 2;
-    }
-    if (arg.GetNumArguments()==2 && !arg.GetArgumentStr(1).IsDigit())
-    {
-        gLog << warn << "WARNING - First argument must not be a number..." << endl;
-        Usage();
-        return 2;
-    }
+    // Get file name(s)
+    //
+    const TString kInput = InflatePath(arg);
+    const TString kTitle = kInput.IsNull() ? kInput + "..."  : kInput;
 
     //
     // Process filenames
     //
-    const TString kInput = InflatePath(arg);
-
     const TString kNamePrint = arg.GetStringAndRemove("--print=",        kInput);
     const TString kPrintCmd  = arg.GetStringAndRemove("--print-cmd=",    kInput);
@@ -255,6 +248,6 @@
 
     // From now on each 'Exit' means: Terminate the application
-    d->SetTitle(kInput);
-    d->SetWindowName(kInput);
+    d->SetTitle(kTitle);
+    d->SetWindowName(kTitle);
 
     if (kCanvasHeight>0)
@@ -263,5 +256,11 @@
         d->SetCanvasWidth(kCanvasWidth);
 
-    const Int_t rc = d->Open(kInput);
+    if (!kInput.IsNull())
+        d->Open(kInput);
+    else
+    {
+        for (int i=0; i<arg.GetNumArguments(); i++)
+            d->Open(arg.GetArgumentStr(i));
+    }
 
     if (kPrint)
@@ -294,5 +293,14 @@
         d->SaveAsC(kTab,    kNameC);
 
-    if (kBatch || kQuit || !rc)
+    if (arg.GetNumArguments()>0)
+    {
+        if (d->GetNumTabs())
+            gLog << all << d->GetNumTabs() << " tab(s) displayed." << endl;
+        else
+            gLog << err << "Display empty... closing." << endl;
+    }
+    gLog << endl;
+
+    if (kBatch || kQuit || (arg.GetNumArguments()>0 && d->GetNumTabs()==0))
     {
         delete d;
