import gnome-settings-daemon-3.32.0-12.el8
This commit is contained in:
parent
eab1629790
commit
70b11d80d5
@ -0,0 +1,125 @@
|
||||
From a8115378fd876bfd4c3871428cdc16134ed484b1 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
||||
Date: Tue, 5 Jan 2021 11:11:18 +0100
|
||||
Subject: [PATCH] media-keys: Mark screen cast as stopped if it was signalled
|
||||
as such
|
||||
|
||||
gnome-shell now sends a 'Stopped' signal if it was stopped without
|
||||
gsd-media-keys itself being the stopper.
|
||||
---
|
||||
plugins/media-keys/gsd-media-keys-manager.c | 52 +++++++++++++++++++--
|
||||
1 file changed, 49 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/plugins/media-keys/gsd-media-keys-manager.c b/plugins/media-keys/gsd-media-keys-manager.c
|
||||
index 4d251f08..a526d5cf 100644
|
||||
--- a/plugins/media-keys/gsd-media-keys-manager.c
|
||||
+++ b/plugins/media-keys/gsd-media-keys-manager.c
|
||||
@@ -210,6 +210,7 @@ struct GsdMediaKeysManagerPrivate
|
||||
guint screencast_timeout_id;
|
||||
gboolean screencast_recording;
|
||||
GCancellable *screencast_cancellable;
|
||||
+ guint screencast_stopped_signal_id;
|
||||
|
||||
/* Rotation */
|
||||
guint iio_sensor_watch_id;
|
||||
@@ -2346,20 +2347,26 @@ do_rfkill_action (GsdMediaKeysManager *manager,
|
||||
}
|
||||
|
||||
static void
|
||||
-screencast_stop (GsdMediaKeysManager *manager)
|
||||
+screencast_stopped (GsdMediaKeysManager *manager)
|
||||
{
|
||||
if (manager->priv->screencast_timeout_id > 0) {
|
||||
g_source_remove (manager->priv->screencast_timeout_id);
|
||||
manager->priv->screencast_timeout_id = 0;
|
||||
}
|
||||
|
||||
+ manager->priv->screencast_recording = FALSE;
|
||||
+}
|
||||
+
|
||||
+static void
|
||||
+screencast_stop (GsdMediaKeysManager *manager)
|
||||
+{
|
||||
+ screencast_stopped (manager);
|
||||
+
|
||||
g_dbus_proxy_call (manager->priv->screencast_proxy,
|
||||
"StopScreencast", NULL,
|
||||
G_DBUS_CALL_FLAGS_NONE, -1,
|
||||
manager->priv->screencast_cancellable,
|
||||
NULL, NULL);
|
||||
-
|
||||
- manager->priv->screencast_recording = FALSE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
@@ -2835,6 +2842,21 @@ initialize_volume_handler (GsdMediaKeysManager *manager)
|
||||
gnome_settings_profile_end ("gvc_mixer_control_new");
|
||||
}
|
||||
|
||||
+
|
||||
+static void
|
||||
+on_screencast_stopped (GDBusConnection *connection,
|
||||
+ const gchar *sender_name,
|
||||
+ const gchar *object_path,
|
||||
+ const gchar *interface_name,
|
||||
+ const gchar *signal_name,
|
||||
+ GVariant *parameters,
|
||||
+ gpointer data)
|
||||
+{
|
||||
+ GsdMediaKeysManager *manager = data;
|
||||
+
|
||||
+ screencast_stopped (manager);
|
||||
+}
|
||||
+
|
||||
static void
|
||||
on_screencast_proxy_ready (GObject *source,
|
||||
GAsyncResult *result,
|
||||
@@ -2850,7 +2872,20 @@ on_screencast_proxy_ready (GObject *source,
|
||||
if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
|
||||
g_warning ("Failed to create proxy for screencast: %s", error->message);
|
||||
g_error_free (error);
|
||||
+ return;
|
||||
}
|
||||
+
|
||||
+ manager->priv->screencast_stopped_signal_id =
|
||||
+ g_dbus_connection_signal_subscribe (manager->priv->connection,
|
||||
+ SHELL_DBUS_NAME ".Screencast",
|
||||
+ SHELL_DBUS_NAME ".Screencast",
|
||||
+ "Stopped",
|
||||
+ SHELL_DBUS_PATH "/Screencast",
|
||||
+ NULL,
|
||||
+ G_DBUS_SIGNAL_FLAGS_NONE,
|
||||
+ on_screencast_stopped,
|
||||
+ manager,
|
||||
+ NULL);
|
||||
}
|
||||
|
||||
static void
|
||||
@@ -2901,6 +2936,11 @@ shell_presence_changed (GsdMediaKeysManager *manager)
|
||||
on_screencast_proxy_ready, manager);
|
||||
g_free (name_owner);
|
||||
} else {
|
||||
+ if (manager->priv->screencast_stopped_signal_id)
|
||||
+ g_dbus_connection_signal_unsubscribe (manager->priv->connection,
|
||||
+ manager->priv->screencast_stopped_signal_id);
|
||||
+ manager->priv->screencast_stopped_signal_id = 0;
|
||||
+
|
||||
g_ptr_array_set_size (manager->priv->keys, 0);
|
||||
g_clear_object (&manager->priv->key_grabber);
|
||||
g_clear_object (&manager->priv->screencast_proxy);
|
||||
@@ -3091,6 +3131,12 @@ gsd_media_keys_manager_stop (GsdMediaKeysManager *manager)
|
||||
priv->reenable_power_button_timer_id = 0;
|
||||
}
|
||||
|
||||
+ if (priv->screencast_stopped_signal_id) {
|
||||
+ g_dbus_connection_signal_unsubscribe (priv->connection,
|
||||
+ priv->screencast_stopped_signal_id);
|
||||
+ priv->screencast_stopped_signal_id = 0;
|
||||
+ }
|
||||
+
|
||||
g_clear_pointer (&manager->priv->ca, ca_context_destroy);
|
||||
|
||||
#if HAVE_GUDEV
|
||||
--
|
||||
2.27.0
|
||||
|
@ -8,7 +8,7 @@
|
||||
|
||||
Name: gnome-settings-daemon
|
||||
Version: 3.32.0
|
||||
Release: 11%{?dist}
|
||||
Release: 12%{?dist}
|
||||
Summary: The daemon sharing settings from GNOME to GTK+/KDE applications
|
||||
|
||||
License: GPLv2+
|
||||
@ -82,6 +82,9 @@ Patch00004: 0004-account-don-t-poll-more-frequently-than-notification.patch
|
||||
Patch00005: 0001-smartcard-Cancel-cancellable-when-stopping.patch
|
||||
Patch00006: 0001-xsettings-Add-an-entry-for-the-overlay-scrolling-set.patch
|
||||
|
||||
# Handle org.gnome.Shell.Screencast Stopped signal (#1705392)
|
||||
Patch00007: 0001-media-keys-Mark-screen-cast-as-stopped-if-it-was-sig.patch
|
||||
|
||||
Patch10001: 0001-housekeeping-Add-a-GPU-memory-usage-notification.patch
|
||||
|
||||
%description
|
||||
@ -105,6 +108,7 @@ developing applications that use %{name}.
|
||||
%patch00004 -p 1
|
||||
%patch00005 -p 1
|
||||
%patch00006 -p 1
|
||||
%patch00007 -p 1
|
||||
|
||||
%patch10001 -p 1
|
||||
|
||||
@ -218,6 +222,10 @@ mkdir $RPM_BUILD_ROOT%{_libdir}/gnome-settings-daemon-3.0/gtk-modules
|
||||
%{_libdir}/pkgconfig/gnome-settings-daemon.pc
|
||||
|
||||
%changelog
|
||||
* Tue Jan 05 2021 Jonas Ådahl <jadahl@redhat.com> - 3.32.0-12
|
||||
- Handle org.gnome.Shell.Screencast Stopped signal
|
||||
Related: #1705392
|
||||
|
||||
* Wed Sep 02 2020 Ray Strode <rstrode@redhat.com> - 3.32.0-11
|
||||
- Remove subman plugin for now
|
||||
Resolves: #1872457
|
||||
|
Loading…
Reference in New Issue
Block a user