Sha256: 7566ca396da62d049620d647a2907fbbf682f9be60804e1f1cf91797261eabff

Contents?: true

Size: 857 Bytes

Versions: 1

Compression:

Stored size: 857 Bytes

Contents

Ext.ns('Rwiki');

Rwiki.ExceptionWindow = Ext.extend(Ext.Window, {

  constructor: function() {
    Ext.apply(this, {
      title: 'Exception',
      layout: 'border',
      maximizable: true,
      width: 750,
      height: 500,
      items: [
        new Ext.Panel({
        html: "<iframe id='exception-iframe' width='100%' height='100%' src=''></iframe>",
        region: 'center'
      })
      ]
    });

    Rwiki.ExceptionWindow.superclass.constructor.apply(this, arguments);
  },

  showResponse: function(response) {
    this.show();

    var ifrm = document.getElementById('exception-iframe');
    ifrm = (ifrm.contentWindow) ? ifrm.contentWindow : (ifrm.contentDocument.document) ? ifrm.contentDocument.document : ifrm.contentDocument;
    ifrm.document.open();
    ifrm.document.write(response.responseText);
    ifrm.document.close();
  }
});

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rwiki-0.2.5 public/javascripts/Rwiki/ExceptionWindow.js