import { ContributionProvider, CommandRegistry, MenuModelRegistry, BackendStopwatch, Stopwatch } from '../common'; import { MaybePromise } from '../common/types'; import { KeybindingRegistry } from './keybinding'; import { ApplicationShell } from './shell/application-shell'; import { ShellLayoutRestorer } from './shell/shell-layout-restorer'; import { FrontendApplicationStateService } from './frontend-application-state'; import { CorePreferences } from './core-preferences'; import { WindowService } from './window/window-service'; import { TooltipService } from './tooltip-service'; import { FrontendApplicationContribution } from './frontend-application-contribution'; export declare class FrontendApplication { protected readonly commands: CommandRegistry; protected readonly menus: MenuModelRegistry; protected readonly keybindings: KeybindingRegistry; protected readonly layoutRestorer: ShellLayoutRestorer; protected readonly contributions: ContributionProvider; protected readonly _shell: ApplicationShell; protected readonly stateService: FrontendApplicationStateService; protected readonly corePreferences: CorePreferences; protected readonly windowsService: WindowService; protected readonly tooltipService: TooltipService; protected readonly stopwatch: Stopwatch; protected readonly backendStopwatch: BackendStopwatch; constructor(commands: CommandRegistry, menus: MenuModelRegistry, keybindings: KeybindingRegistry, layoutRestorer: ShellLayoutRestorer, contributions: ContributionProvider, _shell: ApplicationShell, stateService: FrontendApplicationStateService); get shell(): ApplicationShell; /** * Start the frontend application. * * Start up consists of the following steps: * - start frontend contributions * - attach the application shell to the host element * - initialize the application shell layout * - reveal the application shell if it was hidden by a startup indicator */ start(): Promise; /** * Return a promise to the host element to which the application shell is attached. */ protected getHost(): Promise; /** * Return an HTML element that indicates the startup phase, e.g. with an animation or a splash screen. */ protected getStartupIndicator(host: HTMLElement): HTMLElement | undefined; /** * Register global event listeners. */ protected registerEventListeners(): void; /** * Attach the application shell to the host element. If a startup indicator is present, the shell is * inserted before that indicator so it is not visible yet. */ protected attachShell(host: HTMLElement): void; /** * Attach the tooltip container to the host element. */ protected attachTooltip(host: HTMLElement): void; /** * If a startup indicator is present, it is first hidden with the `theia-hidden` CSS class and then * removed after a while. The delay until removal is taken from the CSS transition duration. */ protected revealShell(host: HTMLElement): Promise; /** * Initialize the shell layout either using the layout restorer service or, if no layout has * been stored, by creating the default layout. */ protected initializeLayout(): Promise; /** * Try to restore the shell layout from the storage service. Resolves to `true` if successful. */ protected restoreLayout(): Promise; /** * Let the frontend application contributions initialize the shell layout. Override this * method in order to create an application-specific custom layout. */ protected createDefaultLayout(): Promise; protected fireOnDidInitializeLayout(): Promise; /** * Initialize and start the frontend application contributions. */ protected startContributions(): Promise; /** * Stop the frontend application contributions. This is called when the window is unloaded. */ protected stopContributions(): void; protected measure(name: string, fn: () => MaybePromise, message?: string, threshold?: boolean): Promise; } //# sourceMappingURL=frontend-application.d.ts.map