Index: trunk/src/event/editor/frame/PropertyModel.java
===================================================================
--- trunk/src/event/editor/frame/PropertyModel.java	(revision 101)
+++ trunk/src/event/editor/frame/PropertyModel.java	(revision 130)
@@ -93,4 +93,18 @@
         notifyObservers(arg);
     }
+    
+    /**
+     * Propagate the window closure.
+     */
+    public void closePanels()
+    {
+        for(JPanel panel : eventMap.keySet())
+        {
+            if(panel instanceof I_ScriptEventEditorPanel)
+            {
+                ((I_ScriptEventEditorPanel) panel).uponClose();
+            }
+        }
+    }
 
     /*
Index: trunk/src/event/editor/frame/Editor.java
===================================================================
--- trunk/src/event/editor/frame/Editor.java	(revision 119)
+++ trunk/src/event/editor/frame/Editor.java	(revision 130)
@@ -124,4 +124,5 @@
                 }
             }
+
         }
 
@@ -150,4 +151,16 @@
             public void keyReleased(KeyEvent e)
             {
+            }
+        });
+        this.addWindowListener(new WindowAdapter()
+        {
+            @Override
+            public void windowClosing(WindowEvent e)
+            {
+                //Add previous offset back in
+                //If we didn't adjust the offset, this will just set it to the old value
+                //If we deleted the first event(s), this will add the offsets,
+                //to ensure that events stay at the correct times
+                model.closePanels();
             }
         });
