1 | "use strict";
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 | Object.defineProperty(exports, "__esModule", { value: true });
|
18 | exports.frontendApplicationModule = exports.bindPreferenceService = exports.bindMessageService = exports.bindResourceProvider = void 0;
|
19 | require("../../src/browser/style/index.css");
|
20 | require('../../src/browser/style/materialcolors.css').use();
|
21 | require("font-awesome/css/font-awesome.min.css");
|
22 | require("file-icons-js/css/style.css");
|
23 | require("@vscode/codicons/dist/codicon.css");
|
24 | const inversify_1 = require("inversify");
|
25 | const common_1 = require("../common");
|
26 | const keybinding_1 = require("./keybinding");
|
27 | const frontend_application_1 = require("./frontend-application");
|
28 | const frontend_application_contribution_1 = require("./frontend-application-contribution");
|
29 | const opener_service_1 = require("./opener-service");
|
30 | const http_open_handler_1 = require("./http-open-handler");
|
31 | const common_frontend_contribution_1 = require("./common-frontend-contribution");
|
32 | const storage_service_1 = require("./storage-service");
|
33 | const widget_manager_1 = require("./widget-manager");
|
34 | const shell_1 = require("./shell");
|
35 | const label_parser_1 = require("./label-parser");
|
36 | const label_provider_1 = require("./label-provider");
|
37 | const preferences_1 = require("./preferences");
|
38 | const context_menu_renderer_1 = require("./context-menu-renderer");
|
39 | const theming_1 = require("./theming");
|
40 | const connection_status_service_1 = require("./connection-status-service");
|
41 | const diff_uris_1 = require("./diff-uris");
|
42 | const application_protocol_1 = require("../common/application-protocol");
|
43 | const messaging_1 = require("./messaging");
|
44 | const about_dialog_1 = require("./about-dialog");
|
45 | const env_variables_1 = require("./../common/env-variables");
|
46 | const frontend_application_state_1 = require("./frontend-application-state");
|
47 | const json_schema_store_1 = require("./json-schema-store");
|
48 | const tab_bar_toolbar_1 = require("./shell/tab-bar-toolbar");
|
49 | const core_preferences_1 = require("./core-preferences");
|
50 | const context_key_service_1 = require("./context-key-service");
|
51 | const resource_context_key_1 = require("./resource-context-key");
|
52 | const keyboard_layout_service_1 = require("./keyboard/keyboard-layout-service");
|
53 | const mime_service_1 = require("./mime-service");
|
54 | const application_shell_mouse_tracker_1 = require("./shell/application-shell-mouse-tracker");
|
55 | const view_container_1 = require("./view-container");
|
56 | const quick_view_service_1 = require("./quick-input/quick-view-service");
|
57 | const dialogs_1 = require("./dialogs");
|
58 | const progress_location_service_1 = require("./progress-location-service");
|
59 | const progress_service_protocol_1 = require("../common/progress-service-protocol");
|
60 | const progress_service_1 = require("../common/progress-service");
|
61 | const progress_client_1 = require("./progress-client");
|
62 | const progress_status_bar_item_1 = require("./progress-status-bar-item");
|
63 | const tab_bar_decorator_1 = require("./shell/tab-bar-decorator");
|
64 | const context_menu_context_1 = require("./menu/context-menu-context");
|
65 | const frontend_application_bindings_1 = require("./frontend-application-bindings");
|
66 | Object.defineProperty(exports, "bindResourceProvider", { enumerable: true, get: function () { return frontend_application_bindings_1.bindResourceProvider; } });
|
67 | Object.defineProperty(exports, "bindMessageService", { enumerable: true, get: function () { return frontend_application_bindings_1.bindMessageService; } });
|
68 | Object.defineProperty(exports, "bindPreferenceService", { enumerable: true, get: function () { return frontend_application_bindings_1.bindPreferenceService; } });
|
69 | const color_registry_1 = require("./color-registry");
|
70 | const color_application_contribution_1 = require("./color-application-contribution");
|
71 | const external_uri_service_1 = require("./external-uri-service");
|
72 | const icon_theme_service_1 = require("./icon-theme-service");
|
73 | const icon_theme_contribution_1 = require("./icon-theme-contribution");
|
74 | const tree_label_provider_1 = require("./tree/tree-label-provider");
|
75 | const progress_bar_1 = require("./progress-bar");
|
76 | const progress_bar_factory_1 = require("./progress-bar-factory");
|
77 | const command_open_handler_1 = require("./command-open-handler");
|
78 | const language_service_1 = require("./language-service");
|
79 | const encoding_registry_1 = require("./encoding-registry");
|
80 | const encoding_service_1 = require("../common/encoding-service");
|
81 | const authentication_service_1 = require("../browser/authentication-service");
|
82 | const decorations_service_1 = require("./decorations-service");
|
83 | const key_store_1 = require("../common/key-store");
|
84 | const credentials_service_1 = require("./credentials-service");
|
85 | const contribution_filter_1 = require("../common/contribution-filter");
|
86 | const quick_command_frontend_contribution_1 = require("./quick-input/quick-command-frontend-contribution");
|
87 | const quick_pick_service_1 = require("../common/quick-pick-service");
|
88 | const quick_input_1 = require("./quick-input");
|
89 | const sidebar_bottom_menu_widget_1 = require("./shell/sidebar-bottom-menu-widget");
|
90 | const window_contribution_1 = require("./window-contribution");
|
91 | const breadcrumbs_1 = require("./breadcrumbs");
|
92 | const widgets_1 = require("./widgets");
|
93 | const tooltip_service_1 = require("./tooltip-service");
|
94 | const request_1 = require("@theia/request");
|
95 | const performance_1 = require("./performance");
|
96 | const save_resource_service_1 = require("./save-resource-service");
|
97 | const secondary_window_handler_1 = require("./secondary-window-handler");
|
98 | const user_working_directory_provider_1 = require("./user-working-directory-provider");
|
99 | const window_title_service_1 = require("./window/window-title-service");
|
100 | const window_title_updater_1 = require("./window/window-title-updater");
|
101 | const theia_dock_panel_1 = require("./shell/theia-dock-panel");
|
102 | const status_bar_1 = require("./status-bar");
|
103 | const markdown_renderer_1 = require("./markdown-rendering/markdown-renderer");
|
104 | const styling_service_1 = require("./styling-service");
|
105 | const common_styling_participants_1 = require("./common-styling-participants");
|
106 | const hover_service_1 = require("./hover-service");
|
107 | const additional_views_menu_widget_1 = require("./shell/additional-views-menu-widget");
|
108 | exports.frontendApplicationModule = new inversify_1.ContainerModule((bind, _unbind, _isBound, _rebind) => {
|
109 | bind(icon_theme_service_1.NoneIconTheme).toSelf().inSingletonScope();
|
110 | bind(label_provider_1.LabelProviderContribution).toService(icon_theme_service_1.NoneIconTheme);
|
111 | bind(icon_theme_service_1.IconThemeService).toSelf().inSingletonScope();
|
112 | (0, common_1.bindContributionProvider)(bind, icon_theme_contribution_1.IconThemeContribution);
|
113 | bind(icon_theme_contribution_1.DefaultFileIconThemeContribution).toSelf().inSingletonScope();
|
114 | bind(icon_theme_contribution_1.IconThemeContribution).toService(icon_theme_contribution_1.DefaultFileIconThemeContribution);
|
115 | bind(icon_theme_contribution_1.IconThemeApplicationContribution).toSelf().inSingletonScope();
|
116 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(icon_theme_contribution_1.IconThemeApplicationContribution);
|
117 | bind(color_registry_1.ColorRegistry).toSelf().inSingletonScope();
|
118 | (0, common_1.bindContributionProvider)(bind, color_application_contribution_1.ColorContribution);
|
119 | bind(color_application_contribution_1.ColorApplicationContribution).toSelf().inSingletonScope();
|
120 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(color_application_contribution_1.ColorApplicationContribution);
|
121 | bind(frontend_application_1.FrontendApplication).toSelf().inSingletonScope();
|
122 | bind(frontend_application_state_1.FrontendApplicationStateService).toSelf().inSingletonScope();
|
123 | bind(frontend_application_contribution_1.DefaultFrontendApplicationContribution).toSelf();
|
124 | (0, common_1.bindContributionProvider)(bind, frontend_application_contribution_1.FrontendApplicationContribution);
|
125 | bind(shell_1.ApplicationShellOptions).toConstantValue({});
|
126 | bind(shell_1.ApplicationShell).toSelf().inSingletonScope();
|
127 | bind(shell_1.SidePanelHandlerFactory).toAutoFactory(shell_1.SidePanelHandler);
|
128 | bind(shell_1.SidePanelHandler).toSelf();
|
129 | bind(shell_1.SidebarTopMenuWidgetFactory).toAutoFactory(shell_1.SidebarMenuWidget);
|
130 | bind(shell_1.SidebarMenuWidget).toSelf();
|
131 | bind(sidebar_bottom_menu_widget_1.SidebarBottomMenuWidget).toSelf();
|
132 | bind(shell_1.SidebarBottomMenuWidgetFactory).toAutoFactory(sidebar_bottom_menu_widget_1.SidebarBottomMenuWidget);
|
133 | bind(additional_views_menu_widget_1.AdditionalViewsMenuWidget).toSelf();
|
134 | bind(additional_views_menu_widget_1.AdditionalViewsMenuWidgetFactory).toFactory(ctx => (side) => {
|
135 | const widget = ctx.container.resolve(additional_views_menu_widget_1.AdditionalViewsMenuWidget);
|
136 | widget.side = side;
|
137 | return widget;
|
138 | });
|
139 | bind(shell_1.SplitPositionHandler).toSelf().inSingletonScope();
|
140 | (0, common_1.bindContributionProvider)(bind, tab_bar_toolbar_1.TabBarToolbarContribution);
|
141 | bind(tab_bar_toolbar_1.TabBarToolbarRegistry).toSelf().inSingletonScope();
|
142 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(tab_bar_toolbar_1.TabBarToolbarRegistry);
|
143 | bind(tab_bar_toolbar_1.TabBarToolbarFactory).toFactory(context => () => {
|
144 | const container = context.container.createChild();
|
145 | container.bind(tab_bar_toolbar_1.TabBarToolbar).toSelf().inSingletonScope();
|
146 | return container.get(tab_bar_toolbar_1.TabBarToolbar);
|
147 | });
|
148 | bind(shell_1.DockPanelRendererFactory).toFactory(context => () => context.container.get(shell_1.DockPanelRenderer));
|
149 | bind(shell_1.DockPanelRenderer).toSelf();
|
150 | bind(shell_1.TabBarRendererFactory).toFactory(({ container }) => () => {
|
151 | const contextMenuRenderer = container.get(context_menu_renderer_1.ContextMenuRenderer);
|
152 | const tabBarDecoratorService = container.get(tab_bar_decorator_1.TabBarDecoratorService);
|
153 | const iconThemeService = container.get(icon_theme_service_1.IconThemeService);
|
154 | const selectionService = container.get(common_1.SelectionService);
|
155 | const commandService = container.get(common_1.CommandService);
|
156 | const corePreferences = container.get(core_preferences_1.CorePreferences);
|
157 | const hoverService = container.get(hover_service_1.HoverService);
|
158 | return new shell_1.TabBarRenderer(contextMenuRenderer, tabBarDecoratorService, iconThemeService, selectionService, commandService, corePreferences, hoverService);
|
159 | });
|
160 | bind(theia_dock_panel_1.TheiaDockPanel.Factory).toFactory(({ container }) => (options) => {
|
161 | const corePreferences = container.get(core_preferences_1.CorePreferences);
|
162 | return new theia_dock_panel_1.TheiaDockPanel(options, corePreferences);
|
163 | });
|
164 | (0, common_1.bindContributionProvider)(bind, tab_bar_decorator_1.TabBarDecorator);
|
165 | bind(tab_bar_decorator_1.TabBarDecoratorService).toSelf().inSingletonScope();
|
166 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(tab_bar_decorator_1.TabBarDecoratorService);
|
167 | (0, common_1.bindContributionProvider)(bind, opener_service_1.OpenHandler);
|
168 | bind(opener_service_1.DefaultOpenerService).toSelf().inSingletonScope();
|
169 | bind(opener_service_1.OpenerService).toService(opener_service_1.DefaultOpenerService);
|
170 | bind(external_uri_service_1.ExternalUriService).toSelf().inSingletonScope();
|
171 | bind(http_open_handler_1.HttpOpenHandler).toSelf().inSingletonScope();
|
172 | bind(opener_service_1.OpenHandler).toService(http_open_handler_1.HttpOpenHandler);
|
173 | bind(command_open_handler_1.CommandOpenHandler).toSelf().inSingletonScope();
|
174 | bind(opener_service_1.OpenHandler).toService(command_open_handler_1.CommandOpenHandler);
|
175 | bind(tooltip_service_1.TooltipServiceImpl).toSelf().inSingletonScope();
|
176 | bind(tooltip_service_1.TooltipService).toService(tooltip_service_1.TooltipServiceImpl);
|
177 | (0, common_1.bindContributionProvider)(bind, shell_1.ApplicationShellLayoutMigration);
|
178 | bind(shell_1.ApplicationShellLayoutMigration).toConstantValue({
|
179 | layoutVersion: 2.0,
|
180 | onWillInflateLayout({ layoutVersion }) {
|
181 | throw shell_1.ApplicationShellLayoutMigrationError.create(`It is not possible to migrate layout of version ${layoutVersion} to version ${this.layoutVersion}.`);
|
182 | }
|
183 | });
|
184 | (0, common_1.bindContributionProvider)(bind, widget_manager_1.WidgetFactory);
|
185 | bind(widget_manager_1.WidgetManager).toSelf().inSingletonScope();
|
186 | bind(shell_1.ShellLayoutRestorer).toSelf().inSingletonScope();
|
187 | bind(common_1.CommandContribution).toService(shell_1.ShellLayoutRestorer);
|
188 | (0, frontend_application_bindings_1.bindResourceProvider)(bind);
|
189 | bind(common_1.InMemoryResources).toSelf().inSingletonScope();
|
190 | bind(common_1.ResourceResolver).toService(common_1.InMemoryResources);
|
191 | bind(common_1.InMemoryTextResourceResolver).toSelf().inSingletonScope();
|
192 | bind(common_1.ResourceResolver).toService(common_1.InMemoryTextResourceResolver);
|
193 | bind(common_1.UntitledResourceResolver).toSelf().inSingletonScope();
|
194 | bind(common_1.ResourceResolver).toService(common_1.UntitledResourceResolver);
|
195 | bind(common_1.SelectionService).toSelf().inSingletonScope();
|
196 | bind(common_1.CommandRegistry).toSelf().inSingletonScope().onActivation(({ container }, registry) => {
|
197 | messaging_1.WebSocketConnectionProvider.createHandler(container, common_1.commandServicePath, registry);
|
198 | return registry;
|
199 | });
|
200 | bind(common_1.CommandService).toService(common_1.CommandRegistry);
|
201 | (0, common_1.bindContributionProvider)(bind, common_1.CommandContribution);
|
202 | bind(context_key_service_1.ContextKeyService).to(context_key_service_1.ContextKeyServiceDummyImpl).inSingletonScope();
|
203 | bind(common_1.MenuModelRegistry).toSelf().inSingletonScope();
|
204 | (0, common_1.bindContributionProvider)(bind, common_1.MenuContribution);
|
205 | bind(common_1.MenuCommandAdapterRegistry).to(common_1.MenuCommandAdapterRegistryImpl).inSingletonScope();
|
206 | bind(common_1.MenuCommandExecutor).to(common_1.MenuCommandExecutorImpl).inSingletonScope();
|
207 | bind(keyboard_layout_service_1.KeyboardLayoutService).toSelf().inSingletonScope();
|
208 | bind(keybinding_1.KeybindingRegistry).toSelf().inSingletonScope();
|
209 | (0, common_1.bindContributionProvider)(bind, keybinding_1.KeybindingContext);
|
210 | (0, common_1.bindContributionProvider)(bind, keybinding_1.KeybindingContribution);
|
211 | (0, frontend_application_bindings_1.bindMessageService)(bind).onActivation(({ container }, messages) => {
|
212 | const client = container.get(common_1.MessageClient);
|
213 | messaging_1.WebSocketConnectionProvider.createHandler(container, common_1.messageServicePath, client);
|
214 | return messages;
|
215 | });
|
216 | bind(language_service_1.LanguageService).toSelf().inSingletonScope();
|
217 | bind(encoding_service_1.EncodingService).toSelf().inSingletonScope();
|
218 | bind(encoding_registry_1.EncodingRegistry).toSelf().inSingletonScope();
|
219 | bind(resource_context_key_1.ResourceContextKey).toSelf().inSingletonScope();
|
220 | bind(common_frontend_contribution_1.CommonFrontendContribution).toSelf().inSingletonScope();
|
221 | [frontend_application_contribution_1.FrontendApplicationContribution, common_1.CommandContribution, keybinding_1.KeybindingContribution, common_1.MenuContribution, color_application_contribution_1.ColorContribution].forEach(serviceIdentifier => bind(serviceIdentifier).toService(common_frontend_contribution_1.CommonFrontendContribution));
|
222 | (0, common_styling_participants_1.bindCommonStylingParticipants)(bind);
|
223 | bind(quick_command_frontend_contribution_1.QuickCommandFrontendContribution).toSelf().inSingletonScope();
|
224 | [common_1.CommandContribution, keybinding_1.KeybindingContribution, common_1.MenuContribution].forEach(serviceIdentifier => bind(serviceIdentifier).toService(quick_command_frontend_contribution_1.QuickCommandFrontendContribution));
|
225 | bind(quick_input_1.QuickCommandService).toSelf().inSingletonScope();
|
226 | bind(quick_input_1.QuickAccessContribution).toService(quick_input_1.QuickCommandService);
|
227 | bind(quick_input_1.QuickHelpService).toSelf().inSingletonScope();
|
228 | bind(quick_input_1.QuickAccessContribution).toService(quick_input_1.QuickHelpService);
|
229 | bind(quick_pick_service_1.QuickPickService).to(quick_input_1.QuickPickServiceImpl).inSingletonScope().onActivation(({ container }, quickPickService) => {
|
230 | messaging_1.WebSocketConnectionProvider.createHandler(container, quick_pick_service_1.quickPickServicePath, quickPickService);
|
231 | return quickPickService;
|
232 | });
|
233 | bind(markdown_renderer_1.MarkdownRenderer).to(markdown_renderer_1.MarkdownRendererImpl).inSingletonScope();
|
234 | bind(markdown_renderer_1.MarkdownRendererFactory).toFactory(({ container }) => () => container.get(markdown_renderer_1.MarkdownRenderer));
|
235 | (0, common_1.bindContributionProvider)(bind, quick_input_1.QuickAccessContribution);
|
236 | bind(quick_input_1.QuickInputFrontendContribution).toSelf().inSingletonScope();
|
237 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(quick_input_1.QuickInputFrontendContribution);
|
238 | bind(storage_service_1.LocalStorageService).toSelf().inSingletonScope();
|
239 | bind(storage_service_1.StorageService).toService(storage_service_1.LocalStorageService);
|
240 | (0, status_bar_1.bindStatusBar)(bind);
|
241 | bind(label_parser_1.LabelParser).toSelf().inSingletonScope();
|
242 | (0, common_1.bindContributionProvider)(bind, label_provider_1.LabelProviderContribution);
|
243 | bind(label_provider_1.LabelProvider).toSelf().inSingletonScope();
|
244 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(label_provider_1.LabelProvider);
|
245 | bind(label_provider_1.DefaultUriLabelProviderContribution).toSelf().inSingletonScope();
|
246 | bind(label_provider_1.LabelProviderContribution).toService(label_provider_1.DefaultUriLabelProviderContribution);
|
247 | bind(label_provider_1.LabelProviderContribution).to(diff_uris_1.DiffUriLabelProviderContribution).inSingletonScope();
|
248 | bind(tree_label_provider_1.TreeLabelProvider).toSelf().inSingletonScope();
|
249 | bind(label_provider_1.LabelProviderContribution).toService(tree_label_provider_1.TreeLabelProvider);
|
250 | (0, frontend_application_bindings_1.bindPreferenceService)(bind);
|
251 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(preferences_1.PreferenceService);
|
252 | (0, common_1.bindContributionProvider)(bind, json_schema_store_1.JsonSchemaContribution);
|
253 | bind(json_schema_store_1.JsonSchemaStore).toSelf().inSingletonScope();
|
254 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(json_schema_store_1.JsonSchemaStore);
|
255 | bind(json_schema_store_1.DefaultJsonSchemaContribution).toSelf().inSingletonScope();
|
256 | bind(json_schema_store_1.JsonSchemaContribution).toService(json_schema_store_1.DefaultJsonSchemaContribution);
|
257 | bind(connection_status_service_1.PingService).toDynamicValue(ctx => {
|
258 |
|
259 | const envServer = ctx.container.get(env_variables_1.EnvVariablesServer);
|
260 | return {
|
261 | ping() {
|
262 | return envServer.getValue('does_not_matter');
|
263 | }
|
264 | };
|
265 | });
|
266 | bind(connection_status_service_1.FrontendConnectionStatusService).toSelf().inSingletonScope();
|
267 | bind(connection_status_service_1.ConnectionStatusService).toService(connection_status_service_1.FrontendConnectionStatusService);
|
268 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(connection_status_service_1.FrontendConnectionStatusService);
|
269 | bind(connection_status_service_1.ApplicationConnectionStatusContribution).toSelf().inSingletonScope();
|
270 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(connection_status_service_1.ApplicationConnectionStatusContribution);
|
271 | bind(application_protocol_1.ApplicationServer).toDynamicValue(ctx => {
|
272 | const provider = ctx.container.get(messaging_1.WebSocketConnectionProvider);
|
273 | return provider.createProxy(application_protocol_1.applicationPath);
|
274 | }).inSingletonScope();
|
275 | bind(about_dialog_1.AboutDialog).toSelf().inSingletonScope();
|
276 | bind(about_dialog_1.AboutDialogProps).toConstantValue({ title: 'Theia' });
|
277 | bind(env_variables_1.EnvVariablesServer).toDynamicValue(ctx => {
|
278 | const connection = ctx.container.get(messaging_1.WebSocketConnectionProvider);
|
279 | return connection.createProxy(env_variables_1.envVariablesPath);
|
280 | }).inSingletonScope();
|
281 | bind(theming_1.ThemeService).toSelf().inSingletonScope();
|
282 | (0, core_preferences_1.bindCorePreferences)(bind);
|
283 | bind(mime_service_1.MimeService).toSelf().inSingletonScope();
|
284 | bind(application_shell_mouse_tracker_1.ApplicationShellMouseTracker).toSelf().inSingletonScope();
|
285 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(application_shell_mouse_tracker_1.ApplicationShellMouseTracker);
|
286 | bind(view_container_1.ViewContainer.Factory).toFactory(context => (options) => {
|
287 | const container = context.container.createChild();
|
288 | container.bind(view_container_1.ViewContainerIdentifier).toConstantValue(options);
|
289 | container.bind(view_container_1.ViewContainer).toSelf().inSingletonScope();
|
290 | return container.get(view_container_1.ViewContainer);
|
291 | });
|
292 | bind(quick_view_service_1.QuickViewService).toSelf().inSingletonScope();
|
293 | bind(quick_input_1.QuickAccessContribution).toService(quick_view_service_1.QuickViewService);
|
294 | bind(dialogs_1.DialogOverlayService).toSelf().inSingletonScope();
|
295 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(dialogs_1.DialogOverlayService);
|
296 | bind(progress_client_1.DispatchingProgressClient).toSelf().inSingletonScope();
|
297 | bind(progress_location_service_1.ProgressLocationService).toSelf().inSingletonScope();
|
298 | bind(progress_status_bar_item_1.ProgressStatusBarItem).toSelf().inSingletonScope();
|
299 | bind(progress_service_protocol_1.ProgressClient).toService(progress_client_1.DispatchingProgressClient);
|
300 | bind(progress_service_1.ProgressService).toSelf().inSingletonScope();
|
301 | bind(progress_bar_factory_1.ProgressBarFactory).toFactory(context => (options) => {
|
302 | const childContainer = context.container.createChild();
|
303 | childContainer.bind(progress_bar_factory_1.ProgressBarOptions).toConstantValue(options);
|
304 | childContainer.bind(progress_bar_1.ProgressBar).toSelf().inSingletonScope();
|
305 | return childContainer.get(progress_bar_1.ProgressBar);
|
306 | });
|
307 | bind(context_menu_context_1.ContextMenuContext).toSelf().inSingletonScope();
|
308 | bind(authentication_service_1.AuthenticationService).to(authentication_service_1.AuthenticationServiceImpl).inSingletonScope();
|
309 | bind(decorations_service_1.DecorationsService).to(decorations_service_1.DecorationsServiceImpl).inSingletonScope();
|
310 | bind(key_store_1.KeyStoreService).toDynamicValue(ctx => {
|
311 | const connection = ctx.container.get(messaging_1.WebSocketConnectionProvider);
|
312 | return connection.createProxy(key_store_1.keyStoreServicePath);
|
313 | }).inSingletonScope();
|
314 | bind(credentials_service_1.CredentialsService).to(credentials_service_1.CredentialsServiceImpl);
|
315 | bind(contribution_filter_1.ContributionFilterRegistry).to(contribution_filter_1.ContributionFilterRegistryImpl).inSingletonScope();
|
316 | bind(window_contribution_1.WindowContribution).toSelf().inSingletonScope();
|
317 | for (const contribution of [common_1.CommandContribution, keybinding_1.KeybindingContribution, common_1.MenuContribution]) {
|
318 | bind(contribution).toService(window_contribution_1.WindowContribution);
|
319 | }
|
320 | bind(window_title_service_1.WindowTitleService).toSelf().inSingletonScope();
|
321 | bind(window_title_updater_1.WindowTitleUpdater).toSelf().inSingletonScope();
|
322 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(window_title_updater_1.WindowTitleUpdater);
|
323 | (0, common_1.bindContributionProvider)(bind, breadcrumbs_1.BreadcrumbsContribution);
|
324 | bind(breadcrumbs_1.BreadcrumbsService).toSelf().inSingletonScope();
|
325 | bind(breadcrumbs_1.BreadcrumbsRenderer).toSelf();
|
326 | bind(breadcrumbs_1.BreadcrumbsRendererFactory).toFactory(ctx => () => {
|
327 | const childContainer = ctx.container.createChild();
|
328 | childContainer.bind(breadcrumbs_1.BreadcrumbRenderer).to(breadcrumbs_1.DefaultBreadcrumbRenderer).inSingletonScope();
|
329 | return childContainer.get(breadcrumbs_1.BreadcrumbsRenderer);
|
330 | });
|
331 | bind(breadcrumbs_1.BreadcrumbPopupContainer).toSelf();
|
332 | bind(breadcrumbs_1.BreadcrumbPopupContainerFactory).toFactory(({ container }) => (parent, breadcrumbId, position) => {
|
333 | const child = container.createChild();
|
334 | child.bind(widgets_1.RendererHost).toConstantValue(parent);
|
335 | child.bind(breadcrumbs_1.BreadcrumbID).toConstantValue(breadcrumbId);
|
336 | child.bind(context_menu_renderer_1.Coordinate).toConstantValue(position);
|
337 | return child.get(breadcrumbs_1.BreadcrumbPopupContainer);
|
338 | });
|
339 | bind(request_1.BackendRequestService).toDynamicValue(ctx => messaging_1.WebSocketConnectionProvider.createProxy(ctx.container, request_1.REQUEST_SERVICE_PATH)).inSingletonScope();
|
340 | (0, performance_1.bindFrontendStopwatch)(bind);
|
341 | (0, performance_1.bindBackendStopwatch)(bind);
|
342 | bind(save_resource_service_1.SaveResourceService).toSelf().inSingletonScope();
|
343 | bind(user_working_directory_provider_1.UserWorkingDirectoryProvider).toSelf().inSingletonScope();
|
344 | bind(hover_service_1.HoverService).toSelf().inSingletonScope();
|
345 | bind(styling_service_1.StylingService).toSelf().inSingletonScope();
|
346 | (0, common_1.bindContributionProvider)(bind, styling_service_1.StylingParticipant);
|
347 | bind(frontend_application_contribution_1.FrontendApplicationContribution).toService(styling_service_1.StylingService);
|
348 | bind(secondary_window_handler_1.SecondaryWindowHandler).toSelf().inSingletonScope();
|
349 | });
|
350 |
|
\ | No newline at end of file |