diff --git a/src/serve/plugins/simulate/static/GUI.js b/src/serve/plugins/simulate/static/GUI.js index 6ca303ee..9e69b59c 100644 --- a/src/serve/plugins/simulate/static/GUI.js +++ b/src/serve/plugins/simulate/static/GUI.js @@ -45,7 +45,7 @@ var GUI = exports = Class(squill.Widget, function(supr) { this.init = function(opts) { supr(this, 'init', arguments); - this._portManager = new PortManager({ range: '9200-9220 exclusive' }); + this._portManager = new PortManager({ range: ''+window.location.port + '-' + (window.location.port + 20) + ' exclusive' }); this._manifest = opts.manifest; this._appID = opts.manifest.appID; diff --git a/src/serve/plugins/simulate/static/util/Simulator.js b/src/serve/plugins/simulate/static/util/Simulator.js index eabb410e..65b3d4a8 100644 --- a/src/serve/plugins/simulate/static/util/Simulator.js +++ b/src/serve/plugins/simulate/static/util/Simulator.js @@ -286,6 +286,8 @@ var Chrome = exports = Class(squill.Widget, function (supr) { var r = new std.uri('/simulate/' + this._appID + '/' + this._params.target + '/') .addQuery(query) .addHash(hash) + .setProtocol("http") + .setHost(window.location.hostname) .setPort(this._port) return r;