[gtk+] displaymanager: Emit display-opened directly
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] displaymanager: Emit display-opened directly
- Date: Fri, 19 Apr 2013 20:27:06 +0000 (UTC)
commit f345051d3671e2321f20aad996f90f57859ae826
Author: Benjamin Otte <otte redhat com>
Date: Wed Apr 17 23:04:05 2013 +0100
displaymanager: Emit display-opened directly
Instead of letting every backend do it manually.
gdk/broadway/gdkdisplay-broadway.c | 1 -
gdk/gdkdisplaymanager.c | 2 ++
gdk/quartz/gdkdisplay-quartz.c | 3 ---
gdk/wayland/gdkdisplay-wayland.c | 1 -
gdk/win32/gdkdisplay-win32.c | 3 ---
gdk/x11/gdkdisplaymanager-x11.c | 2 --
6 files changed, 2 insertions(+), 10 deletions(-)
---
diff --git a/gdk/broadway/gdkdisplay-broadway.c b/gdk/broadway/gdkdisplay-broadway.c
index 7534a9f..58c4622 100644
--- a/gdk/broadway/gdkdisplay-broadway.c
+++ b/gdk/broadway/gdkdisplay-broadway.c
@@ -171,7 +171,6 @@ _gdk_broadway_display_open (const gchar *display_name)
}
g_signal_emit_by_name (display, "opened");
- g_signal_emit_by_name (gdk_display_manager_get (), "display-opened", display);
return display;
}
diff --git a/gdk/gdkdisplaymanager.c b/gdk/gdkdisplaymanager.c
index 95ac309..063aff2 100644
--- a/gdk/gdkdisplaymanager.c
+++ b/gdk/gdkdisplaymanager.c
@@ -505,6 +505,8 @@ _gdk_display_manager_add_display (GdkDisplayManager *manager,
gdk_display_manager_set_default_display (manager, display);
manager->displays = g_slist_prepend (manager->displays, display);
+
+ g_signal_emit (manager, signals[DISPLAY_OPENED], 0, display);
}
/* NB: This function can be called multiple times per display. */
diff --git a/gdk/quartz/gdkdisplay-quartz.c b/gdk/quartz/gdkdisplay-quartz.c
index c953131..17458fc 100644
--- a/gdk/quartz/gdkdisplay-quartz.c
+++ b/gdk/quartz/gdkdisplay-quartz.c
@@ -136,9 +136,6 @@ _gdk_quartz_display_open (const gchar *display_name)
g_signal_emit_by_name (_gdk_display, "opened");
- g_signal_emit_by_name (gdk_display_manager_get (),
- "display_opened", _gdk_display);
-
return _gdk_display;
}
diff --git a/gdk/wayland/gdkdisplay-wayland.c b/gdk/wayland/gdkdisplay-wayland.c
index 06bbf49..d52d8b8 100644
--- a/gdk/wayland/gdkdisplay-wayland.c
+++ b/gdk/wayland/gdkdisplay-wayland.c
@@ -246,7 +246,6 @@ _gdk_wayland_display_open (struct wl_display *wl_display)
gdk_input_init (display);
g_signal_emit_by_name (display, "opened");
- g_signal_emit_by_name (gdk_display_manager_get(), "display_opened", display);
return display;
}
diff --git a/gdk/win32/gdkdisplay-win32.c b/gdk/win32/gdkdisplay-win32.c
index 58bd064..5d9cb14 100644
--- a/gdk/win32/gdkdisplay-win32.c
+++ b/gdk/win32/gdkdisplay-win32.c
@@ -217,9 +217,6 @@ _gdk_win32_display_open (const gchar *display_name)
g_signal_emit_by_name (_gdk_display, "opened");
- g_signal_emit_by_name (gdk_display_manager_get (),
- "display_opened", _gdk_display);
-
GDK_NOTE (MISC, g_print ("... _gdk_display now set up\n"));
return _gdk_display;
diff --git a/gdk/x11/gdkdisplaymanager-x11.c b/gdk/x11/gdkdisplaymanager-x11.c
index 52a2c2b..e550983 100644
--- a/gdk/x11/gdkdisplaymanager-x11.c
+++ b/gdk/x11/gdkdisplaymanager-x11.c
@@ -83,8 +83,6 @@ gdk_x11_display_manager_open_display (GdkDisplayManager *manager,
{
if (gdk_display_manager_get_default_display (manager) == NULL)
gdk_display_manager_set_default_display (manager, display);
-
- g_signal_emit_by_name (manager, "display-opened", display);
}
return display;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]