aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGabriel Luong2013-06-25 15:59:44 (EDT)
committerMark Macdonald2013-06-26 10:08:00 (EDT)
commit2f310719e763b3c9eac0772708c89ce4f99ceb0d (patch)
tree079dc9ea7d1d97951fac956b05fb74660c0db37c
parent3d3305b7b3343aac8735d02e5e7140639fe9588f (diff)
downloadorg.eclipse.orion.client-2f310719e763b3c9eac0772708c89ce4f99ceb0d.zip
org.eclipse.orion.client-2f310719e763b3c9eac0772708c89ce4f99ceb0d.tar.gz
org.eclipse.orion.client-2f310719e763b3c9eac0772708c89ce4f99ceb0d.tar.bz2
Bug 411532 - Save button remains on toolbar after editor goes away
-rw-r--r--bundles/org.eclipse.orion.client.ui/web/edit/setup.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/bundles/org.eclipse.orion.client.ui/web/edit/setup.js b/bundles/org.eclipse.orion.client.ui/web/edit/setup.js
index e424c37..6947577 100644
--- a/bundles/org.eclipse.orion.client.ui/web/edit/setup.js
+++ b/bundles/org.eclipse.orion.client.ui/web/edit/setup.js
@@ -267,6 +267,11 @@ exports.setUpEditor = function(serviceRegistry, preferences, isReadOnly){
});
inputManager.addEventListener("InputChanged", function(evt) { //$NON-NLS-0$
if (evt.input === null || typeof evt.input === "undefined") {//$NON-NLS-0$
+ // remove the toolbar
+ var toolbar = lib.node("pageActions"); //$NON-NLS-0$
+ if (toolbar) {
+ commandRegistry.destroy(toolbar);
+ }
return;
}
var metadata = evt.metadata;