Skip to content

Commit

Permalink
Merge pull request #2873 from bobrippling/rep-fixes
Browse files Browse the repository at this point in the history
rep: interface & recorder fixes
  • Loading branch information
gfwilliams committed Jul 14, 2023
2 parents e408fb9 + 7f0f8cc commit 1add062
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 4 deletions.
2 changes: 2 additions & 0 deletions apps/rep/ChangeLog
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
0.01: New app!
0.02: Fixed interaction with recorder UI listeners
1 change: 1 addition & 0 deletions apps/rep/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,7 @@ var _a, _b, _c;
};
var init = function () {
g.clear();
layout_1.setUI();
drawRep_1();
Bangle.drawWidgets();
};
Expand Down
3 changes: 2 additions & 1 deletion apps/rep/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ class State {
currentRepIndex() {
const elapsed = this.getElapsedTotal();
let ent;
for(let i = 0; ent = reps[i]; i++)
for(let i = 0; (ent = reps[i]); i++)
if(elapsed < ent.accDur)
return i;
return null;
Expand Down Expand Up @@ -316,6 +316,7 @@ const buzzNewRep = () => {

const init = () => {
g.clear();
layout.setUI();
drawRep();

Bangle.drawWidgets();
Expand Down
4 changes: 2 additions & 2 deletions apps/rep/interface.html
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@
}
buttonDelete.appendChild(iconDelete);
buttonDelete.onclick = (e => {
reps = reps.filter(a => a !== alarm);
document.getElementById("events").removeChild(tr);
reps = reps.filter(a => a !== rep);
document.getElementById("repsTable").removeChild(tr);
});
}
tdInfo.appendChild(buttonDelete);
Expand Down
2 changes: 1 addition & 1 deletion apps/rep/metadata.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "rep",
"name": "Rep",
"version":"0.01",
"version":"0.02",
"description": "Time running reps, using a rep schedule/program uploaded via the app loader",
"icon": "app.png",
"tags": "run,running,fitness,outdoors",
Expand Down

0 comments on commit 1add062

Please sign in to comment.