Whitespace fix
[empathy-mirror.git] / libempathy-gtk / empathy-contact-list-view.h
blob97e78d3edf1b1cbe351ff69ab1d42a6774b56c1f
1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
2 /*
3 * Copyright (C) 2005-2007 Imendio AB
4 * Copyright (C) 2007-2008 Collabora Ltd.
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License as
8 * published by the Free Software Foundation; either version 2 of the
9 * License, or (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * General Public License for more details.
16 * You should have received a copy of the GNU General Public
17 * License along with this program; if not, write to the
18 * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
19 * Boston, MA 02110-1301 USA
21 * Authors: Mikael Hallendal <micke@imendio.com>
22 * Martyn Russell <martyn@imendio.com>
23 * Xavier Claessens <xclaesse@gmail.com>
26 #ifndef __EMPATHY_CONTACT_LIST_VIEW_H__
27 #define __EMPATHY_CONTACT_LIST_VIEW_H__
29 #include <gtk/gtk.h>
31 #include <libempathy/empathy-contact.h>
32 #include <libempathy/empathy-enum-types.h>
34 #include "empathy-contact-list-store.h"
35 #include "empathy-live-search.h"
36 #include "empathy-contact-menu.h"
38 G_BEGIN_DECLS
40 #define EMPATHY_TYPE_CONTACT_LIST_VIEW (empathy_contact_list_view_get_type ())
41 #define EMPATHY_CONTACT_LIST_VIEW(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), EMPATHY_TYPE_CONTACT_LIST_VIEW, EmpathyContactListView))
42 #define EMPATHY_CONTACT_LIST_VIEW_CLASS(k) (G_TYPE_CHECK_CLASS_CAST((k), EMPATHY_TYPE_CONTACT_LIST_VIEW, EmpathyContactListViewClass))
43 #define EMPATHY_IS_CONTACT_LIST_VIEW(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), EMPATHY_TYPE_CONTACT_LIST_VIEW))
44 #define EMPATHY_IS_CONTACT_LIST_VIEW_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), EMPATHY_TYPE_CONTACT_LIST_VIEW))
45 #define EMPATHY_CONTACT_LIST_VIEW_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), EMPATHY_TYPE_CONTACT_LIST_VIEW, EmpathyContactListViewClass))
47 typedef struct _EmpathyContactListView EmpathyContactListView;
48 typedef struct _EmpathyContactListViewClass EmpathyContactListViewClass;
50 typedef enum {
51 EMPATHY_CONTACT_LIST_FEATURE_NONE = 0,
52 EMPATHY_CONTACT_LIST_FEATURE_GROUPS_SAVE = 1 << 0,
53 EMPATHY_CONTACT_LIST_FEATURE_GROUPS_RENAME = 1 << 1,
54 EMPATHY_CONTACT_LIST_FEATURE_GROUPS_REMOVE = 1 << 2,
55 EMPATHY_CONTACT_LIST_FEATURE_CONTACT_REMOVE = 1 << 3,
56 EMPATHY_CONTACT_LIST_FEATURE_CONTACT_DROP = 1 << 4,
57 EMPATHY_CONTACT_LIST_FEATURE_CONTACT_DRAG = 1 << 5,
58 EMPATHY_CONTACT_LIST_FEATURE_CONTACT_TOOLTIP = 1 << 6,
59 EMPATHY_CONTACT_LIST_FEATURE_ALL = (1 << 7) - 1,
60 } EmpathyContactListFeatureFlags;
62 struct _EmpathyContactListView {
63 GtkTreeView parent;
64 gpointer priv;
67 struct _EmpathyContactListViewClass {
68 GtkTreeViewClass parent_class;
71 GType empathy_contact_list_view_get_type (void) G_GNUC_CONST;
72 EmpathyContactListView * empathy_contact_list_view_new (EmpathyContactListStore *store,
73 EmpathyContactListFeatureFlags list_features,
74 EmpathyContactFeatureFlags contact_features);
75 EmpathyContact * empathy_contact_list_view_dup_selected (EmpathyContactListView *view);
76 EmpathyContactListFlags empathy_contact_list_view_get_flags (EmpathyContactListView *view);
77 gchar * empathy_contact_list_view_get_selected_group (EmpathyContactListView *view,
78 gboolean *is_fake_group);
79 GtkWidget * empathy_contact_list_view_get_contact_menu (EmpathyContactListView *view);
80 GtkWidget * empathy_contact_list_view_get_group_menu (EmpathyContactListView *view);
81 void empathy_contact_list_view_set_live_search (EmpathyContactListView *view,
82 EmpathyLiveSearch *search);
84 G_END_DECLS
86 #endif /* __EMPATHY_CONTACT_LIST_VIEW_H__ */