Index: trunk/MagicSoft/Mars/mmain/MEventDisplay.cc
===================================================================
--- trunk/MagicSoft/Mars/mmain/MEventDisplay.cc	(revision 2521)
+++ trunk/MagicSoft/Mars/mmain/MEventDisplay.cc	(revision 2550)
@@ -470,12 +470,4 @@
 
     //
-    // Set name for 'FADC canvas'. The name is the anchor for MHCamera.
-    // and clear the canvas
-    //
-    MHEvent *o = (MHEvent*)plist->FindObject("Signal");
-    fCanvas->SetName(Form("%p;%p;PixelContent", o->GetHist(),
-                          GetCanvas(1)->GetPad(1)));
-
-    //
     // Draw ellipse on top of all pads
     //
@@ -520,5 +512,5 @@
 // The other two are parm1 and parm2.
 //
-Bool_t MEventDisplay::ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2)
+Bool_t MEventDisplay::ProcessMessage(Long_t msg, Long_t mp1, Long_t mp2)
 {
     switch (GET_MSG(msg))
@@ -545,6 +537,19 @@
         switch (GET_SUBMSG(msg))
         {
+        case kCM_TAB:
+            {
+                //
+                // Set name for 'FADC canvas'. The name is the anchor for MHCamera.
+                // and clear the canvas
+                //
+                MHEvent *o = (MHEvent*)fEvtLoop->GetParList()->FindObject(GetCanvas(mp1)->GetName());
+                if (o)
+                    fCanvas->SetName(Form("%p;%p;PixelContent", o->GetHist(),
+                                          GetCanvas(mp1)->GetPad(1)));
+            }
+            break;
+
         case kCM_BUTTON:
-            switch (parm1)
+            switch (mp1)
             {
             case kEvtPrev:
@@ -560,4 +565,5 @@
         break;
     }
-    return MStatusDisplay::ProcessMessage(msg, parm1, parm2);
-}
+
+    return MStatusDisplay::ProcessMessage(msg, mp1, mp2);
+}
