about summary refs log tree commit diff stats
path: root/src/otr
Commit message (Expand)AuthorAgeFilesLines
* Always update UI in event loop, removed updates from rest of codeJames Booth2014-09-011-2/+0
* Added license exemption for OpenSSL to source headersJames Booth2014-08-245-0/+60
* Spelling errors fixed and hyphenation used as minus sign fixedDariusz Dwornikowski2014-08-111-1/+1
* Free resources on OTR shutdownJames Booth2014-06-262-2/+16
* Added deallocation function for string prefs, added otr policy enumJames Booth2014-06-183-13/+32
* Fixed memleaks with otr policy and autoaway optionsJames Booth2014-06-171-4/+4
* Fixed memleak in otr.cJames Booth2014-06-151-6/+10
* Added OTR preferences to /account show commmandJames Booth2014-05-111-5/+0
* Implemented per contact OTR policy settingJames Booth2014-05-111-2/+31
* Override global OTR policy with account OTR policyJames Booth2014-05-111-0/+8
* Moved OTR policy check to otr moduleJames Booth2014-05-112-0/+11
* Added question answer messages for libotr 4.0.0James Booth2014-05-071-10/+18
* Added UI messages for smp question/answer resultJames Booth2014-05-071-4/+6
* Added question answer authentication (libotr 3.2.x)James Booth2014-04-303-8/+60
* Added ui functions for otr authenticationJames Booth2014-04-301-4/+2
* Removed debugJames Booth2014-04-302-62/+8
* Attempt at shared secret authentication for libotr 4.0.0James Booth2014-04-285-24/+127
* Added SMP secret libotr 4.0.0 handlersJames Booth2014-04-273-0/+104
* Fixed error on SMP authentication failJames Booth2014-04-271-1/+1
* Added SMP secret authentication success messageJames Booth2014-04-272-0/+6
* Tidied UI messages for SMP shared secret authenticationJames Booth2014-04-272-11/+13
* Added SMP ui eventsJames Booth2014-04-261-6/+6
* Handle SMP secret responseJames Booth2014-04-264-8/+28
* Send SMP init message with /otr secretJames Booth2014-04-264-1/+80
* Fixed cppcheck warningsJames Booth2014-04-261-2/+1
* Merge remote-tracking branch 'lucian/master'James Booth2014-04-222-2/+2
|\
| * Modified otrlibv4 and otrlibv4 to add informative message when starting OTR c...lightb2014-04-222-2/+2
| * Compilation v4 fixlightb2014-04-212-4/+0
| * Added opportunistic send functionality to cmd_msglightb2014-04-212-0/+4
| * Added /otr policy to commands (still need to add autocomplete stuff?)lightb2014-04-191-1/+0
| * Added PREF_OTR_POLICY to preferences.c -> key -> otr.policylightb2014-04-191-0/+1
|/
* Show message in console when contact starts OTR sessionJames Booth2014-04-191-1/+1
* Handle subscription on otr message sendsJames Booth2014-04-181-0/+8
* OTR end messages are now send to recipients not in the roster.James Booth2014-04-181-2/+10
* Fixed compile error when using libotr 4.0.0James Booth2014-04-161-0/+2
* Tidied ui dependenciesJames Booth2014-04-061-2/+0
* Renamed refresh functions to update_virtualJames Booth2014-04-011-1/+1
* Change libotr 4.0.0 code to use only OTR spec v2James Booth2014-03-241-2/+2
* Updated copyrightJames Booth2014-03-095-5/+5
* Added OTR supported versions in initial start query messageJames Booth2014-02-185-0/+22
* Mock otr module for cmd_otr testsJames Booth2014-02-162-45/+67
* Only show error message when err != 0James Booth2014-02-151-4/+6
* Removed free message function from otrlibv3James Booth2014-02-131-6/+0
* Refactored common otr library codeJames Booth2014-02-134-813/+547
* Renamed otr implementationsJames Booth2014-02-122-0/+0
* Moved otr sources into folderJames Booth2014-02-123-0/+1054
mmitter James Booth <boothj5@gmail.com> 2013-07-03 23:44:51 +0100 Coloured contact and subscription in /roster and /group output' href='/danisanti/profani-tty/commit/src/contact.h?id=581c1e8b951d7b9841cec56d5ebf9d3c138e6ce9'>581c1e8b ^
383d91ec ^
6e46e8fe ^

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
  

            
                                                            
  














                                                                       











                                                                                

   


                 

                     

                                     
                                                                           

                                                              
                                                                  
                                                                                  
                                      
                                                
                                             
                                                          
                                                 
                                               
                                                           
                                                                  
                                                           
                                                       
                                                                        
                                                                             
                                                                         

                                                                                         
                                                                                   
                                                        
                                                                  
                                                                                       

                                                                  
                                                                              
                                                      
                                                                                            

      
/*
 * contact.h
 *
 * Copyright (C) 2012 - 2014 James Booth <boothj5@gmail.com>
 *
 * This file is part of Profanity.
 *
 * Profanity is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * Profanity 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.
 *
 * You should have received a copy of the GNU General Public License
 * along with Profanity.  If not, see <http://www.gnu.org/licenses/>.
 *
 * In addition, as a special exception, the copyright holders give permission to
 * link the code of portions of this program with the OpenSSL library under
 * certain conditions as described in each individual source file, and
 * distribute linked combinations including the two.
 *
 * You must obey the GNU General Public License in all respects for all of the
 * code used other than OpenSSL. If you modify file(s) with this exception, you
 * may extend this exception to your version of the file(s), but you are not
 * obligated to do so. If you do not wish to do so, delete this exception
 * statement from your version. If you delete this exception statement from all
 * source files in the program, then also delete it here.
 *
 */

#ifndef CONTACT_H
#define CONTACT_H

#include "resource.h"

typedef struct p_contact_t *PContact;

PContact p_contact_new(const char * const barejid, const char * const name,
    GSList *groups, const char * const subscription,
    const char * const offline_message, gboolean pending_out);
void p_contact_add_resource(PContact contact, Resource *resource);
gboolean p_contact_remove_resource(PContact contact, const char * const resource);
void p_contact_free(PContact contact);
const char* p_contact_barejid(PContact contact);
const char* p_contact_name(PContact contact);
const char* p_contact_name_or_jid(const PContact contact);
const char* p_contact_presence(PContact contact);
const char* p_contact_status(PContact contact);
const char* p_contact_subscription(const PContact contact);
GList * p_contact_get_available_resources(const PContact contact);
GDateTime* p_contact_last_activity(const PContact contact);
gboolean p_contact_pending_out(const PContact contact);
void p_contact_set_presence(const PContact contact, Resource *resource);
void p_contact_set_status(const PContact contact, const char * const status);
void p_contact_set_name(const PContact contact, const char * const name);
void p_contact_set_subscription(const PContact contact, const char * const subscription);
void p_contact_set_pending_out(const PContact contact, gboolean pending_out);
void p_contact_set_last_activity(const PContact contact, GDateTime *last_activity);
gboolean p_contact_is_available(const PContact contact);
gboolean p_contact_has_available_resource(const PContact contact);
Resource * p_contact_get_resource(const PContact contact, const char * const resource);
void p_contact_set_groups(const PContact contact, GSList *groups);
GSList * p_contact_groups(const PContact contact);
gboolean p_contact_in_group(const PContact contact, const char * const group);
gboolean p_contact_subscribed(const PContact contact);
char * p_contact_create_display_string(const PContact contact, const char * const resource);

#endif