Skip to content

Commit 003b917

Browse files
committed
v2.2.4
1 parent cf2969c commit 003b917

8 files changed

+35
-24
lines changed

CHANGELOG.md

+5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## 2.2.3 (September 20, 2023)
2+
- `FIXED` Invalid regex detection of Opera versions 100+ ([#1676](https://github.com/goldfire/howler.js/pull/1676)).
3+
- `FIXED` The `pannerAttr` method wouldn't set the values the first time it was called ([#1497](https://github.com/goldfire/howler.js/issues/1497)).
4+
- `FIXED` Error when refreshing the buffer on a sound that has already been unloaded ([#1508](https://github.com/goldfire/howler.js/issues/1508)).
5+
16
## 2.2.3 (June 30, 2021)
27
- `FIXED` Fatal error in Chrome for iOS ([#1491](https://github.com/goldfire/howler.js/issues/1491)).
38

dist/howler.core.min.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/howler.js

+20-14
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* howler.js v2.2.3
2+
* howler.js v2.2.4
33
* howlerjs.com
44
*
55
* (c) 2013-2020, James Simpson of GoldFire Studios
@@ -265,7 +265,7 @@
265265

266266
// Opera version <33 has mixed MP3 support, so we need to check for and block it.
267267
var ua = self._navigator ? self._navigator.userAgent : '';
268-
var checkOpera = ua.match(/OPR\/([0-6].)/g);
268+
var checkOpera = ua.match(/OPR\/(\d+)/g);
269269
var isOldOpera = (checkOpera && parseInt(checkOpera[0].split('/')[1], 10) < 33);
270270
var checkSafari = ua.indexOf('Safari') !== -1 && ua.indexOf('Chrome') === -1;
271271
var safariVersion = ua.match(/Version\/(.*?) /);
@@ -2167,6 +2167,10 @@
21672167
var self = this;
21682168
var isIOS = Howler._navigator && Howler._navigator.vendor.indexOf('Apple') >= 0;
21692169

2170+
if (!node.bufferSource) {
2171+
return self;
2172+
}
2173+
21702174
if (Howler._scratchBuffer && node.bufferSource) {
21712175
node.bufferSource.onended = null;
21722176
node.bufferSource.disconnect(0);
@@ -2586,7 +2590,7 @@
25862590
/*!
25872591
* Spatial Plugin - Adds support for stereo and 3D audio where Web Audio is supported.
25882592
*
2589-
* howler.js v2.2.3
2593+
* howler.js v2.2.4
25902594
* howlerjs.com
25912595
*
25922596
* (c) 2013-2020, James Simpson of GoldFire Studios
@@ -3099,26 +3103,28 @@
30993103
panningModel: typeof o.panningModel !== 'undefined' ? o.panningModel : pa.panningModel
31003104
};
31013105

3102-
// Update the panner values or create a new panner if none exists.
3106+
// Create a new panner node if one doesn't already exist.
31033107
var panner = sound._panner;
3104-
if (panner) {
3105-
panner.coneInnerAngle = pa.coneInnerAngle;
3106-
panner.coneOuterAngle = pa.coneOuterAngle;
3107-
panner.coneOuterGain = pa.coneOuterGain;
3108-
panner.distanceModel = pa.distanceModel;
3109-
panner.maxDistance = pa.maxDistance;
3110-
panner.refDistance = pa.refDistance;
3111-
panner.rolloffFactor = pa.rolloffFactor;
3112-
panner.panningModel = pa.panningModel;
3113-
} else {
3108+
if (!panner) {
31143109
// Make sure we have a position to setup the node with.
31153110
if (!sound._pos) {
31163111
sound._pos = self._pos || [0, 0, -0.5];
31173112
}
31183113

31193114
// Create a new panner node.
31203115
setupPanner(sound, 'spatial');
3116+
panner = sound._panner
31213117
}
3118+
3119+
// Update the panner values or create a new panner if none exists.
3120+
panner.coneInnerAngle = pa.coneInnerAngle;
3121+
panner.coneOuterAngle = pa.coneOuterAngle;
3122+
panner.coneOuterGain = pa.coneOuterGain;
3123+
panner.distanceModel = pa.distanceModel;
3124+
panner.maxDistance = pa.maxDistance;
3125+
panner.refDistance = pa.refDistance;
3126+
panner.rolloffFactor = pa.rolloffFactor;
3127+
panner.panningModel = pa.panningModel;
31223128
}
31233129
}
31243130

dist/howler.min.js

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/howler.spatial.min.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "howler",
3-
"version": "2.2.3",
3+
"version": "2.2.4",
44
"description": "Javascript audio library for the modern web.",
55
"homepage": "https://howlerjs.com",
66
"keywords": [

src/howler.core.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* howler.js v2.2.3
2+
* howler.js v2.2.4
33
* howlerjs.com
44
*
55
* (c) 2013-2020, James Simpson of GoldFire Studios

src/plugins/howler.spatial.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*!
22
* Spatial Plugin - Adds support for stereo and 3D audio where Web Audio is supported.
33
*
4-
* howler.js v2.2.3
4+
* howler.js v2.2.4
55
* howlerjs.com
66
*
77
* (c) 2013-2020, James Simpson of GoldFire Studios

0 commit comments

Comments
 (0)