|
@@ -132,15 +132,6 @@ function activate(app: JupyterLab, consoleTracker: IConsoleTracker, editorServic
|
|
|
name: widget => widget.context.path
|
|
|
});
|
|
|
|
|
|
- /**
|
|
|
- * Refresh the rendered commands.
|
|
|
- */
|
|
|
- const refreshCommands = () => {
|
|
|
- Object.keys(CommandIDs).forEach(key => {
|
|
|
- app.commands.notifyCommandChanged((CommandIDs as any)[key]);
|
|
|
- });
|
|
|
- };
|
|
|
-
|
|
|
/**
|
|
|
* Update the setting values.
|
|
|
*/
|
|
@@ -151,7 +142,8 @@ function activate(app: JupyterLab, consoleTracker: IConsoleTracker, editorServic
|
|
|
config[key] = (cached[key] === null || cached[key] === undefined) ?
|
|
|
CodeEditor.defaultConfig[key] : cached[key];
|
|
|
});
|
|
|
- refreshCommands();
|
|
|
+ // Trigger a refresh of the rendered commands
|
|
|
+ app.commands.notifyCommandChanged();
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -171,9 +163,6 @@ function activate(app: JupyterLab, consoleTracker: IConsoleTracker, editorServic
|
|
|
});
|
|
|
}
|
|
|
|
|
|
- // Keep the rendered commands up-to-date.
|
|
|
- tracker.currentChanged.connect(refreshCommands);
|
|
|
-
|
|
|
// Add a console creator to the File menu
|
|
|
// Fetch the initial state of the settings.
|
|
|
Promise.all([settingRegistry.load(id), restored]).then(([settings]) => {
|