diff --git a/out/PiPer.safariextz b/out/PiPer.safariextz
new file mode 100644
index 0000000..b1473c6
Binary files /dev/null and b/out/PiPer.safariextz differ
diff --git a/src/scripts/main.js b/src/scripts/main.js
index 52c40f8..d268981 100644
--- a/src/scripts/main.js
+++ b/src/scripts/main.js
@@ -292,17 +292,22 @@ const resources = {
buttonClassName: 'player-button',
buttonDidAppear: function() {
const button = document.getElementById(BUTTON_ID);
- const neighbourTooltip = /** @type {HTMLElement} */ (button.nextSibling.querySelector('.player-tip'));
- const /** string */ previousTitle = neighbourTooltip.dataset['tip'];
+ const neighbourButton = button.nextSibling;
+ const neighbourTooltip = /** @type {HTMLElement} */ (neighbourButton.querySelector('.player-tip'));
+ const /** string */ title = button.title;
+ const /** string */ neighbourTitle = neighbourTooltip.dataset['tip'];
+ button.title = '';
button.addEventListener('mouseover', function(e){
- neighbourTooltip.dataset['tip'] = button.title;
+ neighbourTooltip.dataset['tip'] = title;
neighbourTooltip.style.display = 'block';
- button.title = '';
});
button.addEventListener('mouseout', function(e){
neighbourTooltip.style.display = '';
- button.title = neighbourTooltip.dataset['tip'];
- neighbourTooltip.dataset['tip'] = previousTitle;
+ neighbourTooltip.dataset['tip'] = neighbourTitle;
+ });
+ neighbourButton.addEventListener('click', function(e){
+ const video = /** @type {?HTMLVideoElement} */ (currentResource.videoElement());
+ if (video) video.webkitSetPresentationMode('inline');
});
},
buttonHoverStyle: 'filter:brightness(50%)sepia(1)hue-rotate(219deg)saturate(117%)brightness(112%)',
diff --git a/update.plist b/update.plist
index f84723c..f7d5aa4 100644
--- a/update.plist
+++ b/update.plist
@@ -10,7 +10,7 @@
CFBundleShortVersionString
0.2.0
CFBundleVersion
- 29
+ 30
Developer Identifier
BQ6Q24MF9X
URL