Skip to content

Commit

Permalink
Use the default Theia spinner.
Browse files Browse the repository at this point in the history
Signed-off-by: Akos Kitta <[email protected]>
  • Loading branch information
Akos Kitta committed Jul 8, 2022
1 parent 1aa9e08 commit 50cfe0d
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 57 deletions.
18 changes: 0 additions & 18 deletions arduino-ide-extension/src/browser/style/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -108,21 +108,3 @@ button.theia-button.main {
.fa-reload {
font-size: 14px;
}

/* restore the old Theia spinner */
/* https://github.com/eclipse-theia/theia/pull/10761#issuecomment-1131476318 */
.old-theia-preload {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
z-index: 50000;
background: var(--theia-editor-background);
background-image: var(--theia-preloader);
background-size: 60px 60px;
background-repeat: no-repeat;
background-attachment: fixed;
background-position: center;
transition: opacity 0.8s;
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,26 +32,4 @@ export class FrontendApplication extends TheiaFrontendApplication {
}
});
}

protected override getStartupIndicator(
host: HTMLElement
): HTMLElement | undefined {
let startupElement = this.doGetStartupIndicator(host, 'old-theia-preload'); // https://github.com/eclipse-theia/theia/pull/10761#issuecomment-1131476318
if (!startupElement) {
startupElement = this.doGetStartupIndicator(host, 'theia-preload'); // We show the new Theia spinner in dev mode.
}
return startupElement;
}

private doGetStartupIndicator(
host: HTMLElement,
classNames: string
): HTMLElement | undefined {
const elements = host.getElementsByClassName(classNames);
const first = elements[0];
if (first instanceof HTMLElement) {
return first;
}
return undefined;
}
}
16 changes: 0 additions & 16 deletions electron/build/scripts/patch-theia-preload.js

This file was deleted.

2 changes: 1 addition & 1 deletion electron/build/template-package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"package": "cross-env DEBUG=* && electron-builder --publish=never",
"package:publish": "cross-env DEBUG=* && electron-builder --publish=always",
"download:plugins": "theia download:plugins",
"patch": "ncp ./patch/main.js ./src-gen/backend/main.js && node ./scripts/patch-theia-preload.js ./lib/index.html"
"patch": "ncp ./patch/main.js ./src-gen/backend/main.js"
},
"engines": {
"node": ">=14.0.0 <15"
Expand Down

0 comments on commit 50cfe0d

Please sign in to comment.