Fixes for High contrast mode as per lego design. Most changes are in PXT. Adding high contrast theme in the simulator (#564)

This commit is contained in:
Sam El-Husseini
2018-05-04 10:36:48 -07:00
committed by GitHub
parent 2a371b9cc6
commit f0df0222c0
7 changed files with 36 additions and 29 deletions

View File

@ -19,8 +19,9 @@ namespace pxsim.visuals {
public abstract getInnerWidth(): number;
public abstract getInnerHeight(): number;
public inject(parent: SVGElement, width?: number, visible = true) {
public inject(parent: SVGElement, theme: IBoardTheme, width?: number, visible = true) {
this.width = width;
this.theme = theme;
parent.appendChild(this.getView());
if (visible) {
@ -276,7 +277,7 @@ namespace pxsim.visuals {
}
public addView(view: View) {
view.inject(this.element);
view.inject(this.element, this.theme);
}
public clear() {