11import '../../src/browser/style/index.css' ;
2- import {
3- Container ,
4- ContainerModule ,
5- interfaces ,
6- } from '@theia/core/shared/inversify' ;
2+ import { Container , ContainerModule } from '@theia/core/shared/inversify' ;
73import { WidgetFactory } from '@theia/core/lib/browser/widget-manager' ;
84import { CommandContribution } from '@theia/core/lib/common/command' ;
95import { bindViewContribution } from '@theia/core/lib/browser/shell/view-contribution' ;
106import { TabBarToolbarContribution } from '@theia/core/lib/browser/shell/tab-bar-toolbar' ;
117import { WebSocketConnectionProvider } from '@theia/core/lib/browser/messaging/ws-connection-provider' ;
12- import {
13- FrontendApplicationContribution ,
14- FrontendApplication as TheiaFrontendApplication ,
15- } from '@theia/core/lib/browser/frontend-application' ;
8+ import { FrontendApplication as TheiaFrontendApplication } from '@theia/core/lib/browser/frontend-application' ;
9+ import { FrontendApplicationContribution } from '@theia/core/lib/browser/frontend-application-contribution' ;
1610import { LibraryListWidget } from './library/library-list-widget' ;
1711import { ArduinoFrontendContribution } from './arduino-frontend-contribution' ;
1812import {
@@ -57,8 +51,6 @@ import {
5751 DockPanelRenderer as TheiaDockPanelRenderer ,
5852 TabBarRendererFactory ,
5953 ContextMenuRenderer ,
60- createTreeContainer ,
61- TreeWidget ,
6254} from '@theia/core/lib/browser' ;
6355import { MenuContribution } from '@theia/core/lib/common/menu' ;
6456import {
@@ -97,7 +89,6 @@ import {
9789 ArduinoDaemonPath ,
9890 ArduinoDaemon ,
9991} from '../common/protocol/arduino-daemon' ;
100- import { EditorCommandContribution as TheiaEditorCommandContribution } from '@theia/editor/lib/browser' ;
10192import {
10293 FrontendConnectionStatusService ,
10394 ApplicationConnectionStatusContribution ,
@@ -186,7 +177,6 @@ import {
186177import { About } from './contributions/about' ;
187178import { IconThemeService } from '@theia/core/lib/browser/icon-theme-service' ;
188179import { TabBarRenderer } from './theia/core/tab-bars' ;
189- import { EditorCommandContribution } from './theia/editor/editor-command' ;
190180import { NavigatorTabBarDecorator as TheiaNavigatorTabBarDecorator } from '@theia/navigator/lib/browser/navigator-tab-bar-decorator' ;
191181import { NavigatorTabBarDecorator } from './theia/navigator/navigator-tab-bar-decorator' ;
192182import { Debug , DebugDisabledStatusMessageSource } from './contributions/debug' ;
@@ -275,7 +265,7 @@ import {
275265 IDEUpdaterDialog ,
276266 IDEUpdaterDialogProps ,
277267} from './dialogs/ide-updater/ide-updater-dialog' ;
278- import { ElectronIpcConnectionProvider } from '@theia/core/lib/electron-browser/messaging/electron-ipc-connection-provider ' ;
268+ import { ElectronIpcConnectionProvider } from '@theia/core/lib/electron-browser/messaging/electron-ipc-connection-source ' ;
279269import { MonitorModel } from './monitor-model' ;
280270import { MonitorManagerProxyClientImpl } from './monitor-manager-proxy-client-impl' ;
281271import { EditorManager as TheiaEditorManager } from '@theia/editor/lib/browser/editor-manager' ;
@@ -295,10 +285,6 @@ import { PreferenceTreeGenerator } from './theia/preferences/preference-tree-gen
295285import { PreferenceTreeGenerator as TheiaPreferenceTreeGenerator } from '@theia/preferences/lib/browser/util/preference-tree-generator' ;
296286import { AboutDialog } from './theia/core/about-dialog' ;
297287import { AboutDialog as TheiaAboutDialog } from '@theia/core/lib/browser/about-dialog' ;
298- import {
299- SurveyNotificationService ,
300- SurveyNotificationServicePath ,
301- } from '../common/protocol/survey-service' ;
302288import { WindowContribution } from './theia/core/window-contribution' ;
303289import { WindowContribution as TheiaWindowContribution } from '@theia/core/lib/browser/window-contribution' ;
304290import { CoreErrorHandler } from './contributions/core-error-handler' ;
@@ -381,19 +367,13 @@ import { DebugSessionWidget } from '@theia/debug/lib/browser/view/debug-session-
381367import { DebugConfigurationWidget } from './theia/debug/debug-configuration-widget' ;
382368import { DebugConfigurationWidget as TheiaDebugConfigurationWidget } from '@theia/debug/lib/browser/view/debug-configuration-widget' ;
383369import { DebugToolBar } from '@theia/debug/lib/browser/view/debug-toolbar-widget' ;
384- import {
385- PluginTree ,
386- PluginTreeModel ,
387- TreeViewWidgetOptions ,
388- VIEW_ITEM_CONTEXT_MENU ,
389- } from '@theia/plugin-ext/lib/main/browser/view/tree-view-widget' ;
390- import { TreeViewDecoratorService } from '@theia/plugin-ext/lib/main/browser/view/tree-view-decorator-service' ;
391- import { PLUGIN_VIEW_DATA_FACTORY_ID } from '@theia/plugin-ext/lib/main/browser/view/plugin-view-registry' ;
392- import { TreeViewWidget } from './theia/plugin-ext/tree-view-widget' ;
370+
393371import {
394372 VersionWelcomeDialog ,
395373 VersionWelcomeDialogProps ,
396374} from './dialogs/version-welcome-dialog' ;
375+ import { TestViewContribution as TheiaTestViewContribution } from '@theia/test/lib/browser/view/test-view-contribution' ;
376+ import { TestViewContribution } from './theia/test/test-view-contribution' ;
397377
398378// Hack to fix copy/cut/paste issue after electron version update in Theia.
399379// https://github.com/eclipse-theia/theia/issues/12487
@@ -574,15 +554,6 @@ export default new ContainerModule((bind, unbind, isBound, rebind) => {
574554 WorkspaceVariableContribution
575555 ) ;
576556
577- bind ( SurveyNotificationService )
578- . toDynamicValue ( ( context ) => {
579- return ElectronIpcConnectionProvider . createProxy (
580- context . container ,
581- SurveyNotificationServicePath
582- ) ;
583- } )
584- . inSingletonScope ( ) ;
585-
586557 // Layout and shell customizations.
587558 rebind ( TheiaOutlineViewContribution )
588559 . to ( OutlineViewContribution )
@@ -856,13 +827,6 @@ export default new ContainerModule((bind, unbind, isBound, rebind) => {
856827 ) ;
857828 } ) ;
858829
859- // Workaround for https://github.com/eclipse-theia/theia/issues/8722
860- // Do not trigger a save on IDE startup if `"editor.autoSave": "on"` was set as a preference.
861- // Note: `"editor.autoSave" was renamed to `"files.autoSave" and `"on"` was replaced with three
862- // different cases, but we treat `!== 'off'` as auto save enabled. (https://github.com/eclipse-theia/theia/issues/10812)
863- bind ( EditorCommandContribution ) . toSelf ( ) . inSingletonScope ( ) ;
864- rebind ( TheiaEditorCommandContribution ) . toService ( EditorCommandContribution ) ;
865-
866830 // Silent the badge decoration in the Explorer view.
867831 bind ( NavigatorTabBarDecorator ) . toSelf ( ) . inSingletonScope ( ) ;
868832 rebind ( TheiaNavigatorTabBarDecorator ) . toService ( NavigatorTabBarDecorator ) ;
@@ -1112,42 +1076,7 @@ export default new ContainerModule((bind, unbind, isBound, rebind) => {
11121076 TerminalFrontendContribution
11131077 ) ;
11141078
1115- bindViewsWelcome_TheiaGH14309 ( { bind, widget : TreeViewWidget } ) ;
1079+ // Hides the Test Explorer from the side-bar
1080+ bind ( TestViewContribution ) . toSelf ( ) . inSingletonScope ( ) ;
1081+ rebind ( TheiaTestViewContribution ) . toService ( TestViewContribution ) ;
11161082} ) ;
1117-
1118- // Align the viewsWelcome rendering with VS Code (https://github.com/eclipse-theia/theia/issues/14309)
1119- // Copied from Theia code but with customized TreeViewWidget with the customized viewsWelcome rendering
1120- // https://github.com/eclipse-theia/theia/blob/0c5f69455d9ee355b1a7ca510ffa63d2b20f0c77/packages/plugin-ext/src/main/browser/plugin-ext-frontend-module.ts#L159-L181
1121- function bindViewsWelcome_TheiaGH14309 ( {
1122- bind,
1123- widget,
1124- } : {
1125- bind : interfaces . Bind ;
1126- widget : interfaces . Newable < TreeWidget > ;
1127- } ) {
1128- bind ( WidgetFactory )
1129- . toDynamicValue ( ( { container } ) => ( {
1130- id : PLUGIN_VIEW_DATA_FACTORY_ID ,
1131- createWidget : ( options : TreeViewWidgetOptions ) => {
1132- const props = {
1133- contextMenuPath : VIEW_ITEM_CONTEXT_MENU ,
1134- expandOnlyOnExpansionToggleClick : true ,
1135- expansionTogglePadding : 22 ,
1136- globalSelection : true ,
1137- leftPadding : 8 ,
1138- search : true ,
1139- multiSelect : options . multiSelect ,
1140- } ;
1141- const child = createTreeContainer ( container , {
1142- props,
1143- tree : PluginTree ,
1144- model : PluginTreeModel ,
1145- widget,
1146- decoratorService : TreeViewDecoratorService ,
1147- } ) ;
1148- child . bind ( TreeViewWidgetOptions ) . toConstantValue ( options ) ;
1149- return child . get ( TreeWidget ) ;
1150- } ,
1151- } ) )
1152- . inSingletonScope ( ) ;
1153- }
0 commit comments