]> git.0d.be Git - empathy.git/commitdiff
Port EmpathyLogWindow to new API
authorXavier Claessens <xclaesse@gmail.com>
Thu, 16 Apr 2009 12:28:21 +0000 (12:28 +0000)
committerXavier Claessens <xclaesse@src.gnome.org>
Thu, 16 Apr 2009 12:28:21 +0000 (12:28 +0000)
From: Xavier Claessens <xclaesse@gmail.com>

svn path=/trunk/; revision=2850

libempathy-gtk/empathy-log-window.c

index 24633e5653e17ca25c97c7e7b3697c676d9b686a..2cec17783c52c962b06e170900f430d566993273 100644 (file)
@@ -29,7 +29,6 @@
 
 #include <glib/gi18n-lib.h>
 #include <gtk/gtk.h>
 
 #include <glib/gi18n-lib.h>
 #include <gtk/gtk.h>
-#include <glade/glade.h>
 
 #include <libempathy/empathy-log-manager.h>
 #include <libempathy/empathy-chatroom-manager.h>
 
 #include <libempathy/empathy-log-manager.h>
 #include <libempathy/empathy-chatroom-manager.h>
@@ -144,7 +143,7 @@ empathy_log_window_show (McAccount   *account,
        EmpathyAccountChooser   *account_chooser;
        GList                  *accounts;
        gint                    account_num;
        EmpathyAccountChooser   *account_chooser;
        GList                  *accounts;
        gint                    account_num;
-       GladeXML               *glade;
+       GtkBuilder             *gui;
        gchar                  *filename;
 
        if (window) {
        gchar                  *filename;
 
        if (window) {
@@ -162,11 +161,9 @@ empathy_log_window_show (McAccount   *account,
        window = g_new0 (EmpathyLogWindow, 1);
        window->log_manager = empathy_log_manager_dup_singleton ();
 
        window = g_new0 (EmpathyLogWindow, 1);
        window->log_manager = empathy_log_manager_dup_singleton ();
 
-       filename = empathy_file_lookup ("empathy-log-window.glade",
+       filename = empathy_file_lookup ("empathy-log-window.ui",
                                        "libempathy-gtk");
                                        "libempathy-gtk");
-       glade = empathy_glade_get_file (filename,
-                                      "log_window",
-                                      NULL,
+       gui = empathy_builder_get_file (filename,
                                       "log_window", &window->window,
                                       "notebook", &window->notebook,
                                       "entry_find", &window->entry_find,
                                       "log_window", &window->window,
                                       "notebook", &window->notebook,
                                       "entry_find", &window->entry_find,
@@ -183,8 +180,7 @@ empathy_log_window_show (McAccount   *account,
                                       NULL);
        g_free (filename);
 
                                       NULL);
        g_free (filename);
 
-       empathy_glade_connect (glade,
-                             window,
+       empathy_builder_connect (gui, window,
                              "log_window", "destroy", log_window_destroy_cb,
                              "entry_find", "changed", log_window_entry_find_changed_cb,
                              "button_previous", "clicked", log_window_button_previous_clicked_cb,
                              "log_window", "destroy", log_window_destroy_cb,
                              "entry_find", "changed", log_window_entry_find_changed_cb,
                              "button_previous", "clicked", log_window_button_previous_clicked_cb,
@@ -194,7 +190,7 @@ empathy_log_window_show (McAccount   *account,
                              "entry_chats", "activate", log_window_entry_chats_activate_cb,
                              NULL);
 
                              "entry_chats", "activate", log_window_entry_chats_activate_cb,
                              NULL);
 
-       g_object_unref (glade);
+       g_object_unref (gui);
 
        g_object_add_weak_pointer (G_OBJECT (window->window),
                                   (gpointer) &window);
 
        g_object_add_weak_pointer (G_OBJECT (window->window),
                                   (gpointer) &window);