]> git.0d.be Git - empathy.git/blob - src/empathy-sidebar.h
Merge branch 'debug-window'
[empathy.git] / src / empathy-sidebar.h
1 /*
2  * Copyright (C) 2004 Red Hat, Inc.
3  * Copyright (C) 2007 The Free Software Foundation
4  * Copyright (C) 2008 Marco Barisione <marco@barisione.org>
5  *
6  * Based on evince code (shell/ev-sidebar.h) by:
7  *      - Jonathan Blandford <jrb@alum.mit.edu>
8  *
9  * Base on eog code (src/eog-sidebar.c) by:
10  *      - Lucas Rocha <lucasr@gnome.org>
11  *
12  * This program is free software; you can redistribute it and/or modify
13  * it under the terms of the GNU General Public License as published by
14  * the Free Software Foundation; either version 2 of the License, or
15  * (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
20  * GNU General Public License for more details.
21  *
22  * You should have received a copy of the GNU General Public License
23  * along with this program; if not, write to the Free Software
24  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
25  */
26
27 #ifndef __EMPATHY_SIDEBAR_H__
28 #define __EMPATHY_SIDEBAR_H__
29
30 #include <gtk/gtk.h>
31
32 G_BEGIN_DECLS
33
34 typedef struct _EmpathySidebar EmpathySidebar;
35 typedef struct _EmpathySidebarClass EmpathySidebarClass;
36 typedef struct _EmpathySidebarPrivate EmpathySidebarPrivate;
37
38 #define EMPATHY_TYPE_SIDEBAR            (empathy_sidebar_get_type())
39 #define EMPATHY_SIDEBAR(obj)            (G_TYPE_CHECK_INSTANCE_CAST((obj), EMPATHY_TYPE_SIDEBAR, EmpathySidebar))
40 #define EMPATHY_SIDEBAR_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST((klass),  EMPATHY_TYPE_SIDEBAR, EmpathySidebarClass))
41 #define EMPATHY_IS_SIDEBAR(obj)         (G_TYPE_CHECK_INSTANCE_TYPE((obj), EMPATHY_TYPE_SIDEBAR))
42 #define EMPATHY_IS_SIDEBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),  EMPATHY_TYPE_SIDEBAR))
43 #define EMPATHY_SIDEBAR_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS((obj),  EMPATHY_TYPE_SIDEBAR, EmpathySidebarClass))
44
45 struct _EmpathySidebar
46 {
47   GtkVBox base_instance;
48
49   EmpathySidebarPrivate *priv;
50 };
51
52 struct _EmpathySidebarClass
53 {
54   GtkVBoxClass base_class;
55
56   void (* page_added)   (EmpathySidebar *sidebar,
57                          GtkWidget *main_widget);
58
59   void (* page_removed) (EmpathySidebar *sidebar,
60                          GtkWidget *main_widget);
61 };
62
63 GType      empathy_sidebar_get_type     (void);
64
65 GtkWidget *empathy_sidebar_new          (void);
66
67 void       empathy_sidebar_add_page     (EmpathySidebar *sidebar,
68                                             const gchar *title,
69                                             GtkWidget *main_widget);
70
71 void       empathy_sidebar_remove_page  (EmpathySidebar *sidebar,
72                                             GtkWidget *main_widget);
73
74 void       empathy_sidebar_set_page     (EmpathySidebar *sidebar,
75                                             GtkWidget *main_widget);
76
77 gint       empathy_sidebar_get_n_pages  (EmpathySidebar *sidebar);
78
79 gboolean   empathy_sidebar_is_empty     (EmpathySidebar *sidebar);
80
81 G_END_DECLS
82
83 #endif /* __EMPATHY_SIDEBAR_H__ */
84
85