Update current time on top overlay reveal

Previously current hour might not have been updated if someone entered fullscreen without moving mouse cursor or with a touch
This commit is contained in:
Rafostar
2021-02-20 11:12:50 +01:00
parent 86356d5b1b
commit 46103e169f

View File

@@ -112,6 +112,8 @@ class ClapperWidget extends Gtk.Grid
revealControls(isAllowInput)
{
this._checkSetUpdateTimeInterval();
this.revealerTop.revealChild(true);
this.revealerBottom.revealChild(true);
@@ -157,6 +159,9 @@ class ClapperWidget extends Gtk.Grid
this.revealerTop.revealerGrid.visible = !headerbar.visible;
if(this.revealerTop.child_revealed)
this._checkSetUpdateTimeInterval();
this.setControlsCanFocus(false);
if(this.player.playOnFullscreen && isFullscreen) {
@@ -631,6 +636,17 @@ class ClapperWidget extends Gtk.Grid
});
}
_checkSetUpdateTimeInterval()
{
if(
this.isFullscreenMode
&& !this.isMobileMonitor
&& !this._updateTimeTimeout
) {
this._setUpdateTimeInterval();
}
}
_setUpdateTimeInterval()
{
this._clearTimeout('updateTime');
@@ -872,14 +888,6 @@ class ClapperWidget extends Gtk.Grid
this.needsCursorRestore = false;
}
this.revealControls();
if(
this.isFullscreenMode
&& !this.isMobileMonitor
&& !this._updateTimeTimeout
) {
this._setUpdateTimeInterval();
}
}
this.posX = posX;