This commit was manufactured by cvs2svn to create branch 'gtk2'.
[claws.git] / src / addrclip.h
1 /*
2  * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
3  * Copyright (C) 2002 Match Grun
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18  */
19
20 /*
21  * Address clip board selection.
22  */
23
24 #ifndef __ADDRESS_CLIP_H__
25 #define __ADDRESS_CLIP_H__
26
27 #include <stdio.h>
28 #include <glib.h>
29
30 #include "addrindex.h"
31 #include "addrselect.h"
32
33 /*
34 * Selection data.
35 */
36 typedef struct _AddressClipboard_ AddressClipboard;
37 struct _AddressClipboard_ {
38         gboolean     cutFlag;           /* Indicates cut/copy operation    */
39         gboolean     moveFlag;          /* Internal move indicator for cut */
40         AddressIndex *addressIndex;     /* Reference to address index      */
41         GList        *objectList;       /* List of objects in clipboard    */
42 };
43
44 /*
45 * Function prototypes.
46 */
47 AddressClipboard *addrclip_create       ( void );
48 void addrclip_clear             ( AddressClipboard *clipBoard );
49 void addrclip_free              ( AddressClipboard *clipBoard );
50 void addrclip_set_index         ( AddressClipboard *clipBoard,
51                                   AddressIndex *addrIndex );
52 void addrclip_add               ( AddressClipboard *clipBoard,
53                                   AddrSelectList *asl );
54 /*
55 void addrclip_add               ( AddressClipboard *clipBoard,
56                                   GList *addrList );
57 */
58 void addrclip_add_item          ( AddressClipboard *clipBoard,
59                                   AddrSelectItem *item );
60 gboolean addrclip_is_empty      ( AddressClipboard *clipBoard );
61 void addrclip_list_show         ( AddressClipboard *clipBoard,
62                                   FILE *stream );
63 void addrclip_delete_item       ( AddressClipboard *clipBoard );
64 GList *addrclip_paste_copy      ( AddressClipboard *clipBoard,
65                                   AddressBookFile *book,
66                                   ItemFolder *folder );
67 GList *addrclip_paste_cut       ( AddressClipboard *clipBoard,
68                                   AddressBookFile *book,
69                                   ItemFolder *folder );
70 void addrclip_delete_address    ( AddressClipboard *clipBoard );
71 gint addrclip_paste_person_copy ( AddressClipboard *clipBoard,
72                                   AddressBookFile *book,
73                                   ItemPerson *person );
74 gint addrclip_paste_person_cut  ( AddressClipboard *clipBoard,
75                                   AddressBookFile *book,
76                                   ItemPerson *person );
77
78 #endif /* __ADDRRESS_CLIP_H__ */
79