Skip to content

Commit

Permalink
Move updateDisplayAllBtn() out of visibility update functions
Browse files Browse the repository at this point in the history
  • Loading branch information
yinanazhou committed Oct 31, 2023
1 parent 6f00c22 commit 8056aa5
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/TextView.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,12 @@ class TextView implements TextViewInterface {

document.getElementById('displayText').addEventListener('click', () => {
this.updateTextViewVisibility();
updateDisplayAllBtn();
});

document.getElementById('displayBBox').addEventListener('click', () => {
this.updateBBoxVisibility();
updateDisplayAllBtn();
});
}

Expand Down Expand Up @@ -124,7 +126,6 @@ class TextView implements TextViewInterface {
catch (e) {}
}

updateDisplayAllBtn();
updateHighlight();
}

Expand Down Expand Up @@ -202,8 +203,6 @@ class TextView implements TextViewInterface {
else {
document.getElementById('syl_text').style.display = 'none';
}

updateDisplayAllBtn();
}

/**
Expand Down

0 comments on commit 8056aa5

Please sign in to comment.