Skip to content

Commit e1b6fc5

Browse files
author
thyttan
committed
Merge branch 'app-history-from-fastload-utils' into app-loader
2 parents b93c157 + 750a595 commit e1b6fc5

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

apps/apphist/boot.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@
33
// Seems like `apphist` must be placed before `Fastload Utils` in execution order at boot for compatibility. Otherwise the Bangle.js 2 craps out, freezed up and soon reboots extra hard before loading the clock face again. This is ensured by metadata placing apphist at order 4 and Fastload Utils at order 5 in the boot sequence.
44

55
const s = require("Storage");
6-
const SETTINGS = s.readJSON("apphist.json") || {};
6+
const SETTINGS = s.readJSON("apphist.settings.json") || {};
77

88
global._load = global.load;
99
Bangle._load = Bangle.load;
1010

11-
let appHistory = s.readJSON("apphist.history.json",true)||[];
12-
const resetHistory = ()=>{appHistory=[];s.writeJSON("apphist.history.json",appHistory);};
13-
const recordHistory = ()=>{s.writeJSON("apphist.history.json",appHistory);};
11+
let appHistory = s.readJSON("apphist.json",true)||[];
12+
const resetHistory = ()=>{appHistory=[];s.writeJSON("apphist.json",appHistory);};
13+
const recordHistory = ()=>{s.writeJSON("apphist.json",appHistory);};
1414

1515
const traverseHistory = (name)=>{
1616
if (name && name!=".bootcde" && !(name=="quicklaunch.app.js" && SETTINGS.disregardQuicklaunch)) {

apps/apphist/metadata.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,8 @@
1111
{"name":"apphist.4.boot.js","url":"boot.js"},
1212
{"name":"apphist.settings.js","url":"settings.js"}
1313
],
14-
"data": [{"name":"apphist.json"}]
14+
"data": [
15+
{"name":"apphist.json"},
16+
{"name":"apphist.settings.json"}
17+
]
1518
}

0 commit comments

Comments
 (0)