From 3f40551d6064750b79ffc9228e25318f3a21c81a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Guido=20G=C3=BCnther?= Date: Fri, 14 Apr 2023 10:21:22 +0200 Subject: [PATCH 1/2] splash: Remove keyboard interactivity MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is needed for future phoc that wants to get xdg-activation right. It wasn't of much use except for initial debugging. Signed-off-by: Guido Günther --- src/splash.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/splash.c b/src/splash.c index e1cec32c1..12ad2a976 100644 --- a/src/splash.c +++ b/src/splash.c @@ -150,7 +150,7 @@ phosh_splash_constructed (GObject *object) ZWLR_LAYER_SURFACE_V1_ANCHOR_LEFT | ZWLR_LAYER_SURFACE_V1_ANCHOR_RIGHT, "layer", ZWLR_LAYER_SHELL_V1_LAYER_TOP, - "kbd-interactivity", TRUE, + "kbd-interactivity", FALSE, "exclusive-zone", -1, "namespace", "phosh splash", NULL); -- GitLab From 1656e78521326f16b132bea45c99eb9990c717f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Guido=20G=C3=BCnther?= Date: Fri, 14 Apr 2023 10:27:37 +0200 Subject: [PATCH 2/2] splash: Drop keyboard handling MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Not needed if the layer-surface doesn't allow for keyboard interaction. Signed-off-by: Guido Günther --- src/splash.c | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/src/splash.c b/src/splash.c index 12ad2a976..96a8a9fc5 100644 --- a/src/splash.c +++ b/src/splash.c @@ -159,27 +159,6 @@ phosh_splash_constructed (GObject *object) } -static gboolean -phosh_splash_key_press_event (GtkWidget *self, GdkEventKey *event) -{ - gboolean handled = FALSE; - - g_return_val_if_fail (PHOSH_IS_SPLASH (self), FALSE); - - switch (event->keyval) { - case GDK_KEY_Escape: - g_signal_emit (self, signals[CLOSED], 0); - handled = TRUE; - break; - default: - /* nothing to do */ - break; - } - - return handled; -} - - static void phosh_splash_show (GtkWidget *widget) { @@ -211,7 +190,6 @@ phosh_splash_class_init (PhoshSplashClass *klass) object_class->constructed = phosh_splash_constructed; object_class->dispose = phosh_splash_dispose; widget_class->show = phosh_splash_show; - widget_class->key_press_event = phosh_splash_key_press_event; /** * PhoshSplash:app: -- GitLab