SlideShow: don't send messages from user input in slideshow

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I133050bb38ae7fe404a0520baa17765f44ee259f
This commit is contained in:
Szymon Kłos 2024-07-09 13:32:26 +02:00 committed by Szymon Kłos
parent b8d67500dc
commit 93df205cc6
3 changed files with 6 additions and 2 deletions

View file

@ -447,7 +447,8 @@ L.Map.Keyboard = L.Handler.extend({
return;
app.idleHandler.notifyActive();
if (this._map.slideShow && this._map.slideShow.fullscreen) {
if ((this._map.slideShow && this._map.slideShow.fullscreen) ||
(this._map.slideShowPresenter && this._map.slideShowPresenter.isFullscreen())) {
return;
}

View file

@ -44,7 +44,8 @@ L.Map.Mouse = L.Handler.extend({
app.idleHandler.notifyActive();
var docLayer = this._map._docLayer;
if (!docLayer || (this._map.slideShow && this._map.slideShow.fullscreen) || this._map.rulerActive) {
if (!docLayer || this._map.rulerActive || (this._map.slideShow && this._map.slideShow.fullscreen) ||
(this._map.slideShowPresenter && this._map.slideShowPresenter.isFullscreen())) {
return;
}

View file

@ -63,6 +63,8 @@ class SlideShowPresenter {
return this._presentationInfo ? this._presentationInfo.slides.length : 0;
}
public isFullscreen() { return !!this._fullscreen; }
_onFullScreenChange() {
this._fullscreen = document.fullscreenElement;
if (!this._fullscreen) this._stopFullScreen();