Skip to content
Snippets Groups Projects
App.js 416 B
Newer Older
import Store from "./storage/store";

export class App {
  constructor() {
    this.scene = null;
    this.quality = "low";
  }

  setQuality(quality) {
    if (this.quality === quality) {
      return false;
    }

    this.quality = quality;

    if (this.scene) {
      this.scene.dispatchEvent(new CustomEvent("quality-changed", { detail: quality }));
    }

    return true;
  }
}