Commit 55cde038 authored by wildfirecode13's avatar wildfirecode13

update

parent 27bf398f
...@@ -6,6 +6,7 @@ import Marquee from "../common/Marquee"; ...@@ -6,6 +6,7 @@ import Marquee from "../common/Marquee";
import TestButton from "../common/TestButton"; import TestButton from "../common/TestButton";
import getQueryParams from "../getQueryParams"; import getQueryParams from "../getQueryParams";
import { PrizePanel } from "../panels/prize"; import { PrizePanel } from "../panels/prize";
import { RulePanel } from "../panels/rule";
import { IndexScene } from "./IndexScene"; import { IndexScene } from "./IndexScene";
let prize; let prize;
export class NewbieScene extends Scene { export class NewbieScene extends Scene {
...@@ -40,6 +41,10 @@ export class NewbieScene extends Scene { ...@@ -40,6 +41,10 @@ export class NewbieScene extends Scene {
this.openPrize(this.data); this.openPrize(this.data);
} }
onClick_ruleBtn() {
showPanel(RulePanel);
}
initUi() { initUi() {
super.initUi(); super.initUi();
const group = new Group(); const group = new Group();
...@@ -64,11 +69,13 @@ export class NewbieScene extends Scene { ...@@ -64,11 +69,13 @@ export class NewbieScene extends Scene {
super.initEvents(); super.initEvents();
watchPageVisibility(this.onPageVisibilityChange); watchPageVisibility(this.onPageVisibilityChange);
this.prizeBtn.addEventListener(FYGE.MouseEvent.CLICK, this.onClick_prizeBtn, this); this.prizeBtn.addEventListener(FYGE.MouseEvent.CLICK, this.onClick_prizeBtn, this);
this.ruleBtn.addEventListener(FYGE.MouseEvent.CLICK, this.onClick_ruleBtn, this);
} }
removeEvents() { removeEvents() {
super.removeEvents(); super.removeEvents();
unwatchPageVisibility(this.onPageVisibilityChange) unwatchPageVisibility(this.onPageVisibilityChange)
this.prizeBtn.removeEventListener(FYGE.MouseEvent.CLICK, this.onClick_prizeBtn, this); this.prizeBtn.removeEventListener(FYGE.MouseEvent.CLICK, this.onClick_prizeBtn, this);
this.ruleBtn.removeEventListener(FYGE.MouseEvent.CLICK, this.onClick_ruleBtn, this);
} }
get groupNames() { return ["newbie"] } get groupNames() { return ["newbie"] }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment