Skip to content

Commit

Permalink
Renamed function to BNP.initialize
Browse files Browse the repository at this point in the history
  • Loading branch information
dmotte committed Aug 30, 2024
1 parent 2157252 commit 2d87fa2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions bnplay-audio-api.html
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@
return buffer;
}

static async load() {
static async initialize() {
this.audioData = await this.audioCtx.decodeAudioData(
await this.getSample(),
);
Expand Down Expand Up @@ -149,7 +149,7 @@
const btnToggle = document.getElementById("btnToggle"),
divStatus = document.getElementById("divStatus");

return BNP.load()
return BNP.initialize()
.then(() => {
btnToggle.classList.remove("btn-ctrl-loading");
btnToggle.removeAttribute("disabled");
Expand Down
4 changes: 2 additions & 2 deletions bnplay-audio-tag.html
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
}
}

static load(player1, player2) {
static initialize(player1, player2) {
this.player1 = player1;
this.player2 = player2;
}
Expand Down Expand Up @@ -104,7 +104,7 @@

class UI {
static load() {
BNP.load(
BNP.initialize(
document.getElementById("player1"),
document.getElementById("player2"),
);
Expand Down

0 comments on commit 2d87fa2

Please sign in to comment.