title: Tinymce: How can I check if a window has been closed?
body: <p>Hi I have a plugin that opens a window with a own html-page.</p>
  
  <pre><code>tinymce.PluginManager.add('ds_format_edit', function (editor, url) {
  editor.addMenuItem('ds_format_edit', {
      text: 'Formatvorlage anpassen...',
      icon: false,
      onclick: function () {
          editor.execCommand("ds_format_edit");
      }
  
  });
  
  editor.addCommand('ds_format_edit', function () {
      editor.windowManager.open({
          title: "Formatvorlagen anpassen ...",
          url: 'DSFormatEditDialog.html',
          width: 800,
          height: 350,
          buttons: [
                  {
                      text: 'OK',
                      onclick: function () {
                          top.tinymce.activeEditor.windowManager.close();
                      }
                  },
                  { text: 'Cancel', onclick: 'cancel' }
          ]
      }, {
          tinymce_formats: getFormats(),
      });
  });
  });
  </code></pre>
  
  <p>tinymce_formats is my parameter which I pass to the window. The dialog modify this parameter. All thats works.
  Now I want to reintialize the tinymce editor if the window has been closed (if the user pressed the OK button) to get the modified parameter. 
  <strong>Is there any open callback function or an other way to realize that?</strong>
  Thanks Felix</p>
  
  <p><strong>EDIT:</strong>
  I call this plugin with a Button. The Plugin open a window with a parameter. In this window I do something and modify the parameter. And if the window has been closed I want to use my reintialize function. I need a function which knows when the window is closed to execute the reintialize function.</p>