Skip to content
This repository has been archived by the owner on Apr 4, 2023. It is now read-only.

Commit

Permalink
Do not store state of Welcome page
Browse files Browse the repository at this point in the history
Signed-off-by: Vitaliy Gulyy <vgulyy@redhat.com>
  • Loading branch information
vitaliy-guliy committed Sep 16, 2020
1 parent 503ca56 commit c965874
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions plugins/welcome-plugin/src/welcome-plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,6 @@ export async function addPanel(context: theia.PluginContext): Promise<void> {
export function start(context: theia.PluginContext): void {
let showWelcomePage: boolean | undefined = true;

theia.window.registerWebviewPanelSerializer(welcomePageViewType, new WelcomePageSerializer(context));

const configuration = theia.workspace.getConfiguration(Settings.CHE_CONFIGURATION);
if (configuration) {
showWelcomePage = configuration.get(Settings.SHOW_WELCOME_PAGE);
Expand All @@ -130,14 +128,3 @@ export function start(context: theia.PluginContext): void {

export function stop(): void {
}

export class WelcomePageSerializer implements theia.WebviewPanelSerializer {

constructor(readonly context: theia.PluginContext) {
}

// eslint-disable-next-line @typescript-eslint/no-explicit-any
async deserializeWebviewPanel(webviewPanel: theia.WebviewPanel, state: any): Promise<void> {
webviewPanel.webview.html = await getHtmlForWebview(this.context);
}
}

0 comments on commit c965874

Please sign in to comment.