File tree Expand file tree Collapse file tree 2 files changed +5
-0
lines changed Expand file tree Collapse file tree 2 files changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -157,6 +157,7 @@ export const driveFileBrowser: JupyterFrontEndPlugin<void> = {
157157 }
158158 app . commands . notifyCommandChanged ( CommandIDs . createNewDrive ) ;
159159 app . commands . notifyCommandChanged ( CommandIDs . createNewDirectory ) ;
160+ app . commands . notifyCommandChanged ( CommandIDs . launcher ) ;
160161 } ;
161162
162163 // Listen for path changes.
Original file line number Diff line number Diff line change @@ -44,6 +44,10 @@ function activate(
4444 commands . addCommand ( CommandIDs . launcher , {
4545 label : trans . __ ( 'New Launcher' ) ,
4646 icon : args => ( args . toolbar ? addIcon : undefined ) ,
47+ isEnabled : ( ) => {
48+ const currentBrowser = factory ?. tracker . currentWidget ;
49+ return currentBrowser ?. model . path !== 's3:' ;
50+ } ,
4751 execute : ( args : ReadonlyPartialJSONObject ) => {
4852 // get current file browser used
4953 const currentBrowser = factory ?. tracker . currentWidget ;
You can’t perform that action at this time.
0 commit comments