diff --git a/modules/ve/ui/ve.ui.Context.js b/modules/ve/ui/ve.ui.Context.js index 0a0825b7d0..cfcb47582b 100644 --- a/modules/ve/ui/ve.ui.Context.js +++ b/modules/ve/ui/ve.ui.Context.js @@ -386,11 +386,12 @@ ve.ui.Context.prototype.hide = function () { * * @method * @param {string} name Symbolic name of inspector + * @param {Object} [config] Config options to be sent to the inspector class constructor * @chainable */ -ve.ui.Context.prototype.openInspector = function ( name ) { +ve.ui.Context.prototype.openInspector = function ( name, config ) { if ( !this.inspectors.currentWindow ) { - this.inspectors.open( name ); + this.inspectors.open( name, config ); } return this; }; diff --git a/modules/ve/ui/ve.ui.WindowSet.js b/modules/ve/ui/ve.ui.WindowSet.js index 1c23fc7db0..769dd29553 100644 --- a/modules/ve/ui/ve.ui.WindowSet.js +++ b/modules/ve/ui/ve.ui.WindowSet.js @@ -113,9 +113,10 @@ ve.ui.WindowSet.prototype.getCurrent = function () { * * @method * @param {string} name Symbolic name of window + * @param {Object} [config] Config options to be sent to the window class constructor * @chainable */ -ve.ui.WindowSet.prototype.open = function ( name ) { +ve.ui.WindowSet.prototype.open = function ( name, config ) { var win; if ( !this.factory.lookup( name ) ) { @@ -125,7 +126,7 @@ ve.ui.WindowSet.prototype.open = function ( name ) { throw new Error( 'Cannot open another window while another one is active' ); } if ( !( name in this.windows ) ) { - win = this.windows[name] = this.factory.create( name, this.surface ); + win = this.windows[name] = this.factory.create( name, this.surface, config ); win.connect( this, { 'setup': ['onWindowSetup', win], 'open': ['onWindowOpen', win],