basic progress indication

This commit is contained in:
Matt Walsh
2020-09-07 22:48:10 -05:00
parent 4b7e314d56
commit 57858b562d
4 changed files with 61 additions and 93 deletions

View File

@@ -11,13 +11,14 @@ const STATUS = {
// eslint-disable-next-line no-unused-vars
class WeatherDisplay {
constructor(navId, elemId, canvasWidth, canvasHeight) {
constructor(navId, elemId, name) {
// navId is used in messaging
this.navId = navId;
this.elemId = undefined;
this.gifs = [];
this.data = undefined;
this.loadingStatus = STATUS.loading;
this.name = name?name:elemId;
// default navigation timing
this.timing = {
@@ -29,7 +30,7 @@ class WeatherDisplay {
this.screenIndex = 0;
this.setStatus(STATUS.loading);
this.createCanvas(elemId, canvasWidth, canvasHeight);
this.createCanvas(elemId);
}
// set data status and send update to navigation module