[epiphany/wip/exalm/fullscreen2] fullscreen-box: Minimize delays
- From: Alexander Mikhaylenko <alexm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany/wip/exalm/fullscreen2] fullscreen-box: Minimize delays
- Date: Wed, 24 Mar 2021 12:17:19 +0000 (UTC)
commit ec68b7f266ab9dd8454159b7c45f885a866da89f
Author: Alexander Mikhaylenko <alexm gnome org>
Date: Wed Mar 24 17:14:18 2021 +0500
fullscreen-box: Minimize delays
Only keep the timeout when fullscreening, but not when moving the pointer
away. Make the timeout as small as possible, just enough for the fullscreen
animation to end.
src/ephy-fullscreen-box.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/ephy-fullscreen-box.c b/src/ephy-fullscreen-box.c
index 36c30d5eb..397067ad7 100644
--- a/src/ephy-fullscreen-box.c
+++ b/src/ephy-fullscreen-box.c
@@ -23,7 +23,7 @@
#include <handy.h>
-#define INACTIVITY_TIME_MS 3000
+#define FULLSCREEN_HIDE_DELAY 300
#define SHOW_HEADERBAR_DISTANCE_PX 5
struct _EphyFullscreenBox {
@@ -99,7 +99,9 @@ start_hide_timeout (EphyFullscreenBox *self)
if (self->timeout_id)
return;
- self->timeout_id = g_timeout_add (INACTIVITY_TIME_MS, (GSourceFunc)hide_timeout_cb, self);
+ self->timeout_id = g_timeout_add (FULLSCREEN_HIDE_DELAY,
+ (GSourceFunc)hide_timeout_cb,
+ self);
}
static gboolean
@@ -167,7 +169,7 @@ motion_cb (EphyFullscreenBox *self,
self->is_touch = FALSE;
self->last_y = y;
- update (self, FALSE);
+ update (self, TRUE);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]