Bug 913234 - Close toolboxes on disconnect. r=ochameau

This commit is contained in:
J. Ryan Stinnett 2013-09-10 12:57:48 -05:00
Родитель 66c702ee86
Коммит dc39b70b4f
2 изменённых файлов: 12 добавлений и 3 удалений

Просмотреть файл

@ -167,7 +167,13 @@ let UI = {
openToolbox: function(manifest) { openToolbox: function(manifest) {
this._getTargetForApp(manifest).then((target) => { this._getTargetForApp(manifest).then((target) => {
gDevTools.showToolbox(target, "webconsole", devtools.Toolbox.HostType.WINDOW); gDevTools.showToolbox(target,
null,
devtools.Toolbox.HostType.WINDOW).then(toolbox => {
this.connection.once(Connection.Events.DISCONNECTED, () => {
toolbox.destroy();
});
});
}, console.error); }, console.error);
}, },

Просмотреть файл

@ -223,8 +223,11 @@ let UI = {
this._getTargetForApp(manifest).then((target) => { this._getTargetForApp(manifest).then((target) => {
gDevTools.showToolbox(target, gDevTools.showToolbox(target,
null, null,
devtools.Toolbox.HostType.WINDOW, devtools.Toolbox.HostType.WINDOW).then(toolbox => {
this.connection.uid); this.connection.once(Connection.Events.DISCONNECTED, () => {
toolbox.destroy();
});
});
}, console.error); }, console.error);
}, },