pidgin/gtkscrollbook.c

Mon, 26 Nov 2007 06:30:57 +0000

author
Daniel Atallah <datallah@pidgin.im>
date
Mon, 26 Nov 2007 06:30:57 +0000
changeset 21760
0f73c3c192ac
parent 21719
b4d7c3fe216c
child 21763
95ce28fc860a
permissions
-rw-r--r--

My previous commit caused the scrollbook's children to be tracked correctly - it turns out that this causes problems because they really aren't the children of the scrollbook, they're the notebook'children. This stuff needs to be revisited.

15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
1 /*
15120
cd9d6a7c4296 [gaim-migrate @ 17842]
Sean Egan <seanegan@pidgin.im>
parents: 15119
diff changeset
2 * @file gtkscrollbook.c GTK+ Scrolling notebook widget
16254
eeb2bba4dc94 Rename the Doxygen group from gtkui to pidgin.
Richard Laager <rlaager@pidgin.im>
parents: 15931
diff changeset
3 * @ingroup pidgin
20147
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 19859
diff changeset
4 */
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 19859
diff changeset
5
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 19859
diff changeset
6 /* pidgin
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
7 *
15931
716b5fac1895 Re-sed the copyright notices so they don't all talk about Purple.
Richard Laager <rlaager@pidgin.im>
parents: 15884
diff changeset
8 * Pidgin is the legal property of its developers, whose names are too numerous
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
9 * to list here. Please refer to the COPYRIGHT file distributed with this
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
10 * source distribution.
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
11 *
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
12 * This program is free software; you can redistribute it and/or modify
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
13 * it under the terms of the GNU General Public License as published by
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
14 * the Free Software Foundation; either version 2 of the License, or
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
15 * (at your option) any later version.
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
16 *
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
17 * This program is distributed in the hope that it will be useful,
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
20 * GNU General Public License for more details.
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
21 *
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
22 * You should have received a copy of the GNU General Public License
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
23 * along with this program; if not, write to the Free Software
19859
71d37b57eff2 The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 16254
diff changeset
24 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
25 */
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
26
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
27 #include "gtkscrollbook.h"
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
28
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
29
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
30 static void pidgin_scroll_book_init (PidginScrollBook *scroll_book);
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
31 static void pidgin_scroll_book_class_init (PidginScrollBookClass *klass);
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
32 static void pidgin_scroll_book_forall (GtkContainer *c,
15240
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
33 gboolean include_internals,
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
34 GtkCallback callback,
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
35 gpointer user_data);
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
36
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
37 GType
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
38 pidgin_scroll_book_get_type (void)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
39 {
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
40 static GType scroll_book_type = 0;
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
41
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
42 if (!scroll_book_type)
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
43 {
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
44 static const GTypeInfo scroll_book_info =
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
45 {
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
46 sizeof (PidginScrollBookClass),
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
47 NULL, /* base_init */
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
48 NULL, /* base_finalize */
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
49 (GClassInitFunc) pidgin_scroll_book_class_init,
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
50 NULL, /* class_finalize */
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
51 NULL, /* class_data */
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
52 sizeof (PidginScrollBook),
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
53 0,
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
54 (GInstanceInitFunc) pidgin_scroll_book_init,
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
55 NULL /* value_table */
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
56 };
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
57
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
58 scroll_book_type = g_type_register_static(GTK_TYPE_VBOX,
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
59 "PidginScrollBook",
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
60 &scroll_book_info,
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
61 0);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
62 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
63
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
64 return scroll_book_type;
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
65 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
66
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
67 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
68 scroll_left_cb(PidginScrollBook *scroll_book)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
69 {
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
70 int index;
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
71 index = gtk_notebook_get_current_page(GTK_NOTEBOOK(scroll_book->notebook));
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
72
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
73 if (index > 0)
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
74 gtk_notebook_set_current_page(GTK_NOTEBOOK(scroll_book->notebook), index - 1);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
75 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
76
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
77 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
78 scroll_right_cb(PidginScrollBook *scroll_book)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
79 {
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
80 int index, count;
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
81 index = gtk_notebook_get_current_page(GTK_NOTEBOOK(scroll_book->notebook));
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
82 #if GTK_CHECK_VERSION(2,2,0)
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
83 count = gtk_notebook_get_n_pages(GTK_NOTEBOOK(scroll_book->notebook));
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
84 #else
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
85 count = g_list_length(GTK_NOTEBOOK(scroll_book->notebook)->children);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
86 #endif
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
87
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
88 if (index + 1 < count)
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
89 gtk_notebook_set_current_page(GTK_NOTEBOOK(scroll_book->notebook), index + 1);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
90 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
91
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
92 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
93 refresh_scroll_box(PidginScrollBook *scroll_book, int index, int count)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
94 {
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
95 char *label;
15114
4224e5db3ee4 [gaim-migrate @ 17836]
Mark Doliner <markdoliner@pidgin.im>
parents: 15094
diff changeset
96 gtk_widget_show_all(GTK_WIDGET(scroll_book));
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
97 if (count <= 1)
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
98 gtk_widget_hide(GTK_WIDGET(scroll_book->hbox));
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
99 else
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
100 gtk_widget_show_all(GTK_WIDGET(scroll_book->hbox));
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
101
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
102
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
103 label = g_strdup_printf("<span size='smaller' weight='bold'>(%d/%d)</span>", index+1, count);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
104 gtk_label_set_markup(GTK_LABEL(scroll_book->label), label);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
105 g_free(label);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
106
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
107 if (index == 0)
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
108 gtk_widget_set_sensitive(scroll_book->left_arrow, FALSE);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
109 else
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
110 gtk_widget_set_sensitive(scroll_book->left_arrow, TRUE);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
111
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
112
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
113 if (index +1== count)
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
114 gtk_widget_set_sensitive(scroll_book->right_arrow, FALSE);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
115 else
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
116 gtk_widget_set_sensitive(scroll_book->right_arrow, TRUE);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
117 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
118
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
119
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
120 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
121 page_count_change_cb(PidginScrollBook *scroll_book)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
122 {
15243
87dafc34b920 [gaim-migrate @ 17968]
Sean Egan <seanegan@pidgin.im>
parents: 15240
diff changeset
123 int count;
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
124 int index = gtk_notebook_get_current_page(GTK_NOTEBOOK(scroll_book->notebook));
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
125 #if GTK_CHECK_VERSION(2,2,0)
15243
87dafc34b920 [gaim-migrate @ 17968]
Sean Egan <seanegan@pidgin.im>
parents: 15240
diff changeset
126 count = gtk_notebook_get_n_pages(GTK_NOTEBOOK(scroll_book->notebook));
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
127 #else
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
128 count = g_list_length(GTK_NOTEBOOK(scroll_book->notebook)->children);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
129 #endif
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
130 refresh_scroll_box(scroll_book, index, count);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
131
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
132 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
133
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
134 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
135 switch_page_cb(GtkNotebook *notebook, GtkNotebookPage *page, guint page_num, PidginScrollBook *scroll_book)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
136 {
15320
c4eea0409712 [gaim-migrate @ 18048]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 15246
diff changeset
137 int count;
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
138 #if GTK_CHECK_VERSION(2,2,0)
15320
c4eea0409712 [gaim-migrate @ 18048]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 15246
diff changeset
139 count = gtk_notebook_get_n_pages(GTK_NOTEBOOK(scroll_book->notebook));
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
140 #else
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
141 count = g_list_length(GTK_NOTEBOOK(scroll_book->notebook)->children);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
142 #endif
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
143 refresh_scroll_box(scroll_book, page_num, count);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
144 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
145
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
146 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
147 pidgin_scroll_book_add(GtkContainer *container, GtkWidget *widget)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
148 {
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
149 PidginScrollBook *scroll_book;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
150
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
151 g_return_if_fail(GTK_IS_WIDGET (widget));
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
152 g_return_if_fail (widget->parent == NULL);
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
153
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
154 scroll_book = PIDGIN_SCROLL_BOOK(container);
21719
b4d7c3fe216c I'm pretty sure this is what was intended.
Daniel Atallah <datallah@pidgin.im>
parents: 21670
diff changeset
155 scroll_book->children = g_list_append(scroll_book->children, widget);
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
156 gtk_widget_show(widget);
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
157 gtk_notebook_append_page(GTK_NOTEBOOK(PIDGIN_SCROLL_BOOK(container)->notebook), widget, NULL);
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
158 page_count_change_cb(PIDGIN_SCROLL_BOOK(container));
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
159 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
160
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
161 static void
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
162 pidgin_scroll_book_remove(GtkContainer *container, GtkWidget *widget)
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
163 {
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
164 int page;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
165 GList *children;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
166 GtkWidget *child;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
167 PidginScrollBook *scroll_book;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
168 g_return_if_fail(GTK_IS_WIDGET(widget));
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
169
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
170 scroll_book = PIDGIN_SCROLL_BOOK(container);
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
171 children = scroll_book->children;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
172
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
173 while (children) {
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
174 child = children->data;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
175 if (child == widget) {
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
176 gtk_widget_unparent (widget);
21719
b4d7c3fe216c I'm pretty sure this is what was intended.
Daniel Atallah <datallah@pidgin.im>
parents: 21670
diff changeset
177 scroll_book->children = g_list_delete_link(scroll_book->children, children);
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
178 break;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
179 }
21719
b4d7c3fe216c I'm pretty sure this is what was intended.
Daniel Atallah <datallah@pidgin.im>
parents: 21670
diff changeset
180 children = children->next;
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
181 }
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
182
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
183 page = gtk_notebook_page_num(GTK_NOTEBOOK(PIDGIN_SCROLL_BOOK(container)->notebook), widget);
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
184 if (page >= 0) {
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
185 gtk_notebook_remove_page(GTK_NOTEBOOK(PIDGIN_SCROLL_BOOK(container)->notebook), page);
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
186 }
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
187 }
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
188
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
189 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
190 pidgin_scroll_book_forall(GtkContainer *container,
15240
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
191 gboolean include_internals,
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
192 GtkCallback callback,
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
193 gpointer callback_data)
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
194 {
21760
0f73c3c192ac My previous commit caused the scrollbook's children to be tracked correctly - it turns out that this causes problems because they really aren't the children of the scrollbook, they're the notebook'children. This stuff needs to be revisited.
Daniel Atallah <datallah@pidgin.im>
parents: 21719
diff changeset
195 #if 0
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
196 GList *children;
21760
0f73c3c192ac My previous commit caused the scrollbook's children to be tracked correctly - it turns out that this causes problems because they really aren't the children of the scrollbook, they're the notebook'children. This stuff needs to be revisited.
Daniel Atallah <datallah@pidgin.im>
parents: 21719
diff changeset
197 #endif
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
198 PidginScrollBook *scroll_book;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
199
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
200 g_return_if_fail(GTK_IS_CONTAINER(container));
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
201
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
202 scroll_book = PIDGIN_SCROLL_BOOK(container);
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
203
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
204 if (include_internals) {
15240
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
205 (*callback)(scroll_book->hbox, callback_data);
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
206 (*callback)(scroll_book->notebook, callback_data);
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
207 }
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
208
21760
0f73c3c192ac My previous commit caused the scrollbook's children to be tracked correctly - it turns out that this causes problems because they really aren't the children of the scrollbook, they're the notebook'children. This stuff needs to be revisited.
Daniel Atallah <datallah@pidgin.im>
parents: 21719
diff changeset
209 #if 0
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
210 children = scroll_book->children;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
211
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
212 while (children) {
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
213 GtkWidget *child;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
214 child = children->data;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
215 children = children->next;
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
216 (*callback)(child, callback_data);
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
217 }
21760
0f73c3c192ac My previous commit caused the scrollbook's children to be tracked correctly - it turns out that this causes problems because they really aren't the children of the scrollbook, they're the notebook'children. This stuff needs to be revisited.
Daniel Atallah <datallah@pidgin.im>
parents: 21719
diff changeset
218 #endif
15240
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
219 }
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
220
3aa0e80143e8 [gaim-migrate @ 17965]
Sean Egan <seanegan@pidgin.im>
parents: 15190
diff changeset
221 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
222 pidgin_scroll_book_class_init (PidginScrollBookClass *klass)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
223 {
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
224 GtkContainerClass *container_class = (GtkContainerClass*)klass;
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
225
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
226 container_class->add = pidgin_scroll_book_add;
21670
9ce6e7374523 This fixes the problem where all accounts are disabled due to connection
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 20147
diff changeset
227 container_class->remove = pidgin_scroll_book_remove;
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
228 container_class->forall = pidgin_scroll_book_forall;
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
229
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
230 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
231
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
232 static void
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
233 pidgin_scroll_book_init (PidginScrollBook *scroll_book)
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
234 {
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
235 GtkWidget *eb;
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
236
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
237 scroll_book->hbox = gtk_hbox_new(FALSE, 0);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
238
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
239 eb = gtk_event_box_new();
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
240 gtk_box_pack_end(GTK_BOX(scroll_book->hbox), eb, FALSE, FALSE, 0);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
241 scroll_book->right_arrow = gtk_arrow_new(GTK_ARROW_RIGHT, GTK_SHADOW_NONE);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
242 gtk_container_add(GTK_CONTAINER(eb), scroll_book->right_arrow);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
243 g_signal_connect_swapped(G_OBJECT(eb), "button-press-event", G_CALLBACK(scroll_right_cb), scroll_book);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
244
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
245 scroll_book->label = gtk_label_new(NULL);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
246 gtk_box_pack_end(GTK_BOX(scroll_book->hbox), scroll_book->label, FALSE, FALSE, 0);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
247
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
248 eb = gtk_event_box_new();
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
249 gtk_box_pack_end(GTK_BOX(scroll_book->hbox), eb, FALSE, FALSE, 0);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
250 scroll_book->left_arrow = gtk_arrow_new(GTK_ARROW_LEFT, GTK_SHADOW_NONE);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
251 gtk_container_add(GTK_CONTAINER(eb), scroll_book->left_arrow);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
252 g_signal_connect_swapped(G_OBJECT(eb), "button-press-event", G_CALLBACK(scroll_left_cb), scroll_book);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
253
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
254 gtk_box_pack_start(GTK_BOX(scroll_book), scroll_book->hbox, FALSE, FALSE, 0);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
255
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
256 scroll_book->notebook = gtk_notebook_new();
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
257 gtk_notebook_set_show_tabs(GTK_NOTEBOOK(scroll_book->notebook), FALSE);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
258 gtk_notebook_set_show_border(GTK_NOTEBOOK(scroll_book->notebook), FALSE);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
259
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
260 gtk_box_pack_start(GTK_BOX(scroll_book), scroll_book->notebook, TRUE, TRUE, 0);
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
261
15190
4ce2829864f0 [gaim-migrate @ 17914]
Mark Doliner <markdoliner@pidgin.im>
parents: 15120
diff changeset
262 g_signal_connect_swapped(G_OBJECT(scroll_book->notebook), "remove", G_CALLBACK(page_count_change_cb), scroll_book);
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
263 g_signal_connect(G_OBJECT(scroll_book->notebook), "switch-page", G_CALLBACK(switch_page_cb), scroll_book);
15243
87dafc34b920 [gaim-migrate @ 17968]
Sean Egan <seanegan@pidgin.im>
parents: 15240
diff changeset
264 gtk_widget_show_all(scroll_book->notebook);
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
265 }
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
266
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
267
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
268
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
269 GtkWidget *
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
270 pidgin_scroll_book_new()
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
271 {
15577
b8129373f65e More pidgin changes
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
272 return g_object_new(PIDGIN_TYPE_SCROLL_BOOK, NULL);
15094
7ebf5dd7d969 [gaim-migrate @ 17815]
Sean Egan <seanegan@pidgin.im>
parents:
diff changeset
273 }

mercurial