# HG changeset patch
# Node ID a92aa5a5192cd4fd51ff2f48f3d6803574ab5353
# Parent  54cb1cfca9ae49e7202d6fbe0d941cab109f5703
diff --git a/pidgin/pidginapplication.c b/pidgin/pidginapplication.c
--- a/pidgin/pidginapplication.c
+++ b/pidgin/pidginapplication.c
@@ -852,10 +852,16 @@ pidgin_application_startup(GApplication 
 
 static void
 pidgin_application_activate(G_GNUC_UNUSED GApplication *application) {
-	GtkWidget *convwin = pidgin_display_window_get_default();
+	static GtkWidget *default_window = NULL;
 
-	if(GTK_IS_WINDOW(convwin)) {
-		gtk_window_present(GTK_WINDOW(convwin));
+	if(!GTK_IS_WIDGET(default_window)) {
+		default_window = pidgin_display_window_new();
+		g_object_add_weak_pointer(G_OBJECT(default_window),
+		                          (gpointer)&default_window);
+	}
+
+	if(GTK_IS_WINDOW(default_window)) {
+		gtk_window_present(GTK_WINDOW(default_window));
 	}
 }
 
diff --git a/pidgin/pidgindisplaywindow.c b/pidgin/pidgindisplaywindow.c
--- a/pidgin/pidgindisplaywindow.c
+++ b/pidgin/pidgindisplaywindow.c
@@ -58,8 +58,6 @@ struct _PidginDisplayWindow {
 G_DEFINE_FINAL_TYPE(PidginDisplayWindow, pidgin_display_window,
                     GTK_TYPE_APPLICATION_WINDOW)
 
-static GtkWidget *default_window = NULL;
-
 /******************************************************************************
  * Helpers
  *****************************************************************************/
@@ -356,6 +354,7 @@ pidgin_display_window_init(PidginDisplay
 	GtkTreeListModel *tree_model = NULL;
 	GSimpleActionGroup *conversation_actions = NULL;
 	GPluginManager *plugin_manager = NULL;
+	PurpleConversationManager *conversation_manager = NULL;
 	gpointer settings_backend = NULL;
 
 	gtk_widget_init_template(GTK_WIDGET(window));
@@ -406,6 +405,14 @@ pidgin_display_window_init(PidginDisplay
 	settings_backend = purple_core_get_settings_backend();
 	gplugin_gtk_view_set_settings_backend(GPLUGIN_GTK_VIEW(window->plugin_list),
 	                                      settings_backend);
+
+	conversation_manager = purple_conversation_manager_get_default();
+	g_signal_connect_object(conversation_manager, "added",
+	                        G_CALLBACK(pidgin_display_window_conversation_added_cb),
+	                        window, 0);
+	g_signal_connect_object(conversation_manager, "removed",
+	                        G_CALLBACK(pidgin_display_window_conversation_removed_cb),
+	                        window, 0);
 }
 
 static void
@@ -471,27 +478,6 @@ pidgin_display_window_class_init(PidginD
  * API
  *****************************************************************************/
 GtkWidget *
-pidgin_display_window_get_default(void) {
-	if(!GTK_IS_WIDGET(default_window)) {
-		PurpleConversationManager *manager = NULL;
-
-		default_window = pidgin_display_window_new();
-		g_object_add_weak_pointer(G_OBJECT(default_window),
-		                          (gpointer)&default_window);
-
-		manager = purple_conversation_manager_get_default();
-		g_signal_connect_object(manager, "added",
-		                        G_CALLBACK(pidgin_display_window_conversation_added_cb),
-		                        default_window, 0);
-		g_signal_connect_object(manager, "removed",
-		                        G_CALLBACK(pidgin_display_window_conversation_removed_cb),
-		                        default_window, 0);
-	}
-
-	return default_window;
-}
-
-GtkWidget *
 pidgin_display_window_new(void) {
 	return g_object_new(
 		PIDGIN_TYPE_DISPLAY_WINDOW,
diff --git a/pidgin/pidgindisplaywindow.h b/pidgin/pidgindisplaywindow.h
--- a/pidgin/pidgindisplaywindow.h
+++ b/pidgin/pidgindisplaywindow.h
@@ -64,18 +64,6 @@ PIDGIN_AVAILABLE_IN_3_0
 GtkWidget *pidgin_display_window_new(void);
 
 /**
- * pidgin_display_window_get_default:
- *
- * Gets or creates the default conversation window.
- *
- * Returns: (transfer none): The default #PidginDisplayWindow.
- *
- * Since: 3.0
- */
-PIDGIN_AVAILABLE_IN_3_0
-GtkWidget *pidgin_display_window_get_default(void);
-
-/**
  * pidgin_display_window_add:
  * @window: The #PidginDisplayWindow instance.
  * @conversation: The #PurpleConversation to add to @window.
