]> git.0d.be Git - empathy.git/blob - tests/interactive/test-empathy-account-chooser.c
Use double quotes for all internal headers
[empathy.git] / tests / interactive / test-empathy-account-chooser.c
1 #include <config.h>
2
3 #include <gtk/gtk.h>
4
5 #include "libempathy-gtk/empathy-ui-utils.h"
6 #include "libempathy-gtk/empathy-account-chooser.h"
7
8 static void
9 filter_func (TpAccount *account,
10     EmpathyAccountChooserFilterResultCallback callback,
11     gpointer callback_data,
12     gpointer user_data)
13 {
14   g_assert (TP_IS_ACCOUNT (account));
15   callback (TRUE, callback_data);
16 }
17
18 int
19 main (int argc,
20     char **argv)
21 {
22   GtkWidget *window, *c;
23
24   gtk_init (&argc, &argv);
25   empathy_gtk_init ();
26
27   window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
28   c = empathy_account_chooser_new ();
29
30   empathy_account_chooser_set_has_all_option (EMPATHY_ACCOUNT_CHOOSER (c),
31       TRUE);
32
33   empathy_account_chooser_set_filter (EMPATHY_ACCOUNT_CHOOSER (c),
34       filter_func, NULL);
35
36   gtk_container_add (GTK_CONTAINER (window), c);
37
38   /*  gtk_window_set_default_size (GTK_WINDOW (window), 150, -1);*/
39   gtk_widget_show_all (window);
40
41   g_signal_connect_swapped (window, "destroy",
42       G_CALLBACK (gtk_main_quit), NULL);
43
44   gtk_main ();
45
46   return 0;
47 }