calltree.h 2.03 KB
Newer Older
Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
1 2
/*
 *  Copyright (C) 2007 Savoir-Faire Linux inc.
3
 *  Author: Pierre-Luc Beaudoin <pierre-luc.beaudoin@savoirfairelinux.com>
4
 *
Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
5 6
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
7
 *  the Free Software Foundation; either version 3 of the License, or
Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
8
 *  (at your option) any later version.
9
 *
Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
10 11 12 13
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
14
 *
Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
15 16 17 18
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 */
19

Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
20 21 22 23
#ifndef __CALLTREE_H__
#define __CALLTREE_H__

#include <gtk/gtk.h>
Emmanuel Milou's avatar
Emmanuel Milou committed
24

25
#include <calllist.h>
areversat's avatar
areversat committed
26
#include <calltab.h>
Emmanuel Milou's avatar
Emmanuel Milou committed
27
#include <timestamp.h>
28

Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
29

Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
30 31 32
/** @file calltree.h
  * @brief The GtkTreeView that list calls in the main window.
  */
areversat's avatar
areversat committed
33

Julien Bonjean's avatar
Julien Bonjean committed
34 35
GtkWidget * filter_entry;

areversat's avatar
areversat committed
36
calltab_t* active_calltree;
37 38 39

void free_call_t (call_t *c);

40 41 42 43
/**
 * Create a new widget calltree
 * @return GtkWidget* A new widget
 */
44
void create_call_tree(calltab_t* tab);
Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
45

46 47 48
/**
 * Update the toolbar's buttons state, according to the call state
 */
49 50
void toolbar_update_buttons();

51 52 53 54
/**
 * Add a call in the calltree
 * @param c The call to add
 */
55
void update_call_tree_add (calltab_t* ct, call_t * c);
Emmanuel Milou's avatar
Emmanuel Milou committed
56 57

/*
58 59
 * Update the call tree if the call state changes
 * @param c The call to update
60
 */
61
void update_call_tree (calltab_t* ct, call_t * c);
62 63 64 65
/**
 * Remove a call from the call tree
 * @param c The call to remove
 */
66
void update_call_tree_remove (calltab_t* ct, call_t * c);
Pierre-Luc Beaudoin's avatar
Pierre-Luc Beaudoin committed
67

68 69
void reset_call_tree (calltab_t* tab);

70 71 72 73
/**
 * Build the toolbar
 * @return GtkWidget* The toolbar
 */
74 75
GtkWidget * create_toolbar();

76
void display_calltree (calltab_t *tab);
Julien Bonjean's avatar
Julien Bonjean committed
77

78
void create_new_entry_in_contactlist (gchar *contact_name, gchar *contact_phone, contact_type_t type, GdkPixbuf *photo);
79

80
#endif