33 * Licensed under the MIT License. See License.txt in the project root for license information.
44 *--------------------------------------------------------------------------------------------*/
55
6- import { IWorkbenchConstructionOptions , create , ICredentialsProvider , IURLCallbackProvider , IWorkspaceProvider , IWorkspace , IWindowIndicator , ICommand , IHomeIndicator , IProductQualityChangeHandler } from 'vs/workbench/workbench.web.api' ;
7- import product from 'vs/platform/product/common/product' ;
6+ import { IWorkbenchConstructionOptions , create , ICredentialsProvider , IURLCallbackProvider , IWorkspaceProvider , IWorkspace , IWindowIndicator , IHomeIndicator , IProductQualityChangeHandler } from 'vs/workbench/workbench.web.api' ;
87import { URI , UriComponents } from 'vs/base/common/uri' ;
98import { Event , Emitter } from 'vs/base/common/event' ;
109import { generateUuid } from 'vs/base/common/uuid' ;
@@ -302,8 +301,6 @@ class WindowIndicator implements IWindowIndicator {
302301 readonly tooltip : string ;
303302 readonly command : string | undefined ;
304303
305- readonly commandImpl : ICommand | undefined = undefined ;
306-
307304 constructor ( workspace : IWorkspace ) {
308305 let repositoryOwner : string | undefined = undefined ;
309306 let repositoryName : string | undefined = undefined ;
@@ -321,20 +318,16 @@ class WindowIndicator implements IWindowIndicator {
321318 }
322319 }
323320
321+ // Repo
324322 if ( repositoryName && repositoryOwner ) {
325- this . label = localize ( 'openInDesktopLabel' , "$(remote) Open in Desktop" ) ;
326- this . tooltip = localize ( 'openInDesktopTooltip' , "Open in Desktop" ) ;
327- this . command = '_web.openInDesktop' ;
328- this . commandImpl = {
329- id : this . command ,
330- handler : ( ) => {
331- const protocol = product . quality === 'stable' ? 'vscode' : 'vscode-insiders' ;
332- window . open ( `${ protocol } ://vscode.git/clone?url=${ encodeURIComponent ( `https://github.com/${ repositoryOwner } /${ repositoryName } .git` ) } ` ) ;
333- }
334- } ;
335- } else {
336- this . label = localize ( 'playgroundLabel' , "Web Playground" ) ;
337- this . tooltip = this . label ;
323+ this . label = localize ( 'playgroundLabelRepository' , "$(remote) VS Code Web Playground: {0}/{1}" , repositoryOwner , repositoryName ) ;
324+ this . tooltip = localize ( 'playgroundRepositoryTooltip' , "VS Code Web Playground: {0}/{1}" , repositoryOwner , repositoryName ) ;
325+ }
326+
327+ // No Repo
328+ else {
329+ this . label = localize ( 'playgroundLabel' , "$(remote) VS Code Web Playground" ) ;
330+ this . tooltip = localize ( 'playgroundTooltip' , "VS Code Web Playground" ) ;
338331 }
339332 }
340333}
@@ -416,16 +409,10 @@ class WindowIndicator implements IWindowIndicator {
416409 title : localize ( 'home' , "Home" )
417410 } ;
418411
419- // Commands
420- const commands : ICommand [ ] = [ ] ;
421-
422412 // Window indicator (unless connected to a remote)
423413 let windowIndicator : WindowIndicator | undefined = undefined ;
424414 if ( ! workspaceProvider . hasRemote ( ) ) {
425415 windowIndicator = new WindowIndicator ( workspace ) ;
426- if ( windowIndicator . commandImpl ) {
427- commands . push ( windowIndicator . commandImpl ) ;
428- }
429416 }
430417
431418 // Product Quality Change Handler
@@ -447,7 +434,6 @@ class WindowIndicator implements IWindowIndicator {
447434 create ( document . body , {
448435 ...config ,
449436 homeIndicator,
450- commands,
451437 windowIndicator,
452438 productQualityChangeHandler,
453439 workspaceProvider,
0 commit comments