aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/config.json1
-rw-r--r--src/index.js4
-rw-r--r--src/js/background.js11
3 files changed, 15 insertions, 1 deletions
diff --git a/src/config.json b/src/config.json
index 5c1e8c2..fb94d9d 100644
--- a/src/config.json
+++ b/src/config.json
@@ -17,6 +17,7 @@
"icon": "fas fa-music"
}
],
+ "background": "webapps-html5-background",
"launch": "webapps-html5-launcher",
"network": {
"bluetooth": "fab fa-bluetooth-b",
diff --git a/src/index.js b/src/index.js
index 9d2cce0..8198355 100644
--- a/src/index.js
+++ b/src/index.js
@@ -22,8 +22,10 @@ import { api } from 'agl-js-api';
import * as app from './js/app';
import * as apps from './js/apps';
import * as time from './js/time';
+import * as background from './js/background';
window.apps = apps;
window.time = time;
api.init();
-app.init(); \ No newline at end of file
+background.load();
+app.init();
diff --git a/src/js/background.js b/src/js/background.js
new file mode 100644
index 0000000..38408ed
--- /dev/null
+++ b/src/js/background.js
@@ -0,0 +1,11 @@
+import { homescreen, afmMain } from 'agl-js-api';
+
+var configjson = require('../config.json');
+
+export function load() {
+ afmMain.start(configjson.background).then(function(result) {
+ console.log("loading background: " + result);
+ });
+}
+
+