Index: trunk/FACT++/gui/RawEventsViewer/RawEventsViewer.cc
===================================================================
--- trunk/FACT++/gui/RawEventsViewer/RawEventsViewer.cc	(revision 19367)
+++ trunk/FACT++/gui/RawEventsViewer/RawEventsViewer.cc	(revision 19368)
@@ -563,5 +563,5 @@
  * OPEN FILE. opens a new fits file
  ************************************************************/
-void RawDataViewer::openFile(string& file)
+void RawDataViewer::openFile(string file, bool reopen)
 {
     if (inputFile)
@@ -571,5 +571,5 @@
     }
     try {
-    inputFile = new factfits(file, "Events");
+        inputFile = reopen && fIsDrsCalibration ? new zfits(file, "Events") :  new factfits(file, "Events");
     }
     catch (std::runtime_error e)
@@ -761,10 +761,15 @@
 
 
-    int backupStep = eventStep;
-    rowNum = -1;
-    eventStep = 1;
-
-    plusEvent();
-    eventStep = backupStep;
+    if (!reopen)
+    {
+        int backupStep = eventStep;
+        rowNum = -1;
+        eventStep = 1;
+        plusEvent();
+        eventStep = backupStep;
+    }
+    else
+        readEvent();
+
     emit newFileLoaded();
     emit signalCurrentPixel(selectedPixel);
@@ -933,4 +938,9 @@
         rowNum += nRows;
 
+    readEvent();
+}
+
+void RawDataViewer::readEvent()
+{
     if (inputFile == NULL)
         return;
@@ -1084,7 +1094,4 @@
     initHistograms();
 
-    currentFile = "none";
-    currentCalibFile = "none";
-
     updateSpinnerDisplay = true;
     updating = false;
@@ -1165,5 +1172,10 @@
 {
     GLWindow->fIsDrsCalibration = state;
+
+    if (currentCalibFile.empty())
+        GLWindow->openFile(currentFile, true);
+
     GLWindow->ApplyCalibration();
+
     threeD_Window->setData(GLWindow->eventData);
 
@@ -1292,13 +1304,21 @@
 void UIConnector::fileSelected(QString file)
 {
+    const bool reopen = !currentFile.empty();
+
     currentFile = file.toStdString();
-    if (currentFile != "")
-        GLWindow->openFile(currentFile);
+    if (!currentFile.empty())
+        GLWindow->openFile(currentFile, reopen && currentCalibFile.empty());
 }
 void UIConnector::calibFileSelected(QString file)
 {
+    const bool reopen = currentCalibFile.empty();
+
     currentCalibFile = file.toStdString();
+    if (reopen && !currentFile.empty())
+        GLWindow->openFile(currentFile, true);
     if (currentCalibFile != "")
         GLWindow->openCalibFile(currentCalibFile);
+
+
     if (GLWindow->fDrsCalib.fRoi != 0)
     {//spread the calibration data to the displayers
Index: trunk/FACT++/gui/RawEventsViewer/RawEventsViewer.h
===================================================================
--- trunk/FACT++/gui/RawEventsViewer/RawEventsViewer.h	(revision 19367)
+++ trunk/FACT++/gui/RawEventsViewer/RawEventsViewer.h	(revision 19368)
@@ -52,5 +52,5 @@
     RawDataViewer(QWidget *parent = 0);
     ~RawDataViewer();
-    void openFile(std::string& file);
+    void openFile(std::string file, bool reopen);
     void openCalibFile(std::string& file);
 
@@ -65,4 +65,5 @@
     void plusEvent();
     void minusEvent();
+    void readEvent();
     void setEventStep(int step);
     void nextSlice();
