[gnome-bluetooth] lib: Replace gtk_widget_get_toplevel() by gtk_widget_get_native()
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-bluetooth] lib: Replace gtk_widget_get_toplevel() by gtk_widget_get_native()
- Date: Thu, 28 Oct 2021 15:29:58 +0000 (UTC)
commit fe1ba190bde21e41ddd44493330e57e5261bfff1
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Wed Oct 27 12:52:36 2021 -0300
lib: Replace gtk_widget_get_toplevel() by gtk_widget_get_native()
For all intents and purposes, all knowin GtkNatives are toplevels.
lib/bluetooth-settings-widget.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/lib/bluetooth-settings-widget.c b/lib/bluetooth-settings-widget.c
index b29f5cc2..85aed150 100644
--- a/lib/bluetooth-settings-widget.c
+++ b/lib/bluetooth-settings-widget.c
@@ -247,7 +247,7 @@ setup_pairing_dialog (BluetoothSettingsWidget *self)
g_clear_pointer ((GtkWindow**)&priv->pairing_dialog, gtk_window_destroy);
priv->pairing_dialog = bluetooth_pairing_dialog_new ();
- toplevel = gtk_widget_get_toplevel (GTK_WIDGET (self));
+ toplevel = GTK_WIDGET (gtk_widget_get_native (GTK_WIDGET (self)));
gtk_window_set_transient_for (GTK_WINDOW (priv->pairing_dialog), GTK_WINDOW (toplevel));
gtk_window_set_modal (GTK_WINDOW (priv->pairing_dialog), TRUE);
}
@@ -1514,7 +1514,7 @@ activate_row (BluetoothSettingsWidget *self,
g_object_unref (proxy);
w = priv->properties_dialog;
- toplevel = gtk_widget_get_toplevel (GTK_WIDGET (self));
+ toplevel = GTK_WIDGET (gtk_widget_get_native (GTK_WIDGET (self)));
gtk_window_set_transient_for (GTK_WINDOW (w), GTK_WINDOW (toplevel));
gtk_window_set_modal (GTK_WINDOW (w), TRUE);
gtk_window_present (GTK_WINDOW (w));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]