1 #ifndef __TRADE_LOG_H
2 #define __TRADE_LOG_H
3 
4 #ifdef __cplusplus
5 extern "C" {
6 #endif
7 
8 #include "trade.h"
9 
10 // The trade log mode, set by the options window, as described in the enum
11 extern int trade_log_mode;
12 enum { TRADE_LOG_NONE = 0, TRADE_LOG_CONSOLE, TRADE_LOG_FILE, TRADE_LOG_BOTH };
13 
14 /**
15  * @ingroup trade_log
16  * @brief We are sending the server "Accept" for the second time.
17  *
18  * @param name	the name of the person we are trading with
19  * @param yours	the list of items we are trading
20  * @param others	the list of items they are trading with us
21  * @param max_items	the maximum size of the item lists
22  * @callgraph
23  */
24 void trade_accepted(const char *name, const trade_item *yours, const trade_item *others, int max_items);
25 
26 /**
27  * @ingroup trade_log
28  * @brief server has sent the GET_TRADE_EXIT command.
29  *
30  * @callgraph
31  */
32 void trade_exit(void);
33 
34 /**
35  * @ingroup trade_log
36  * @brief server has sent the trade window abort text message
37  *
38  * @param message	The text of the message
39  * @callgraph
40  */
41 void trade_aborted(const char *message);
42 
43 /**
44  * @ingroup trade_log
45  * @brief server has sent the STORAGE_ITEMS command.
46  *
47  * @callgraph
48  */
49 void trade_post_storage(void);
50 
51 /**
52  * @ingroup trade_log
53  * @brief server has sent the HERE_YOUR_INVENTORY command.
54  *
55  * @callgraph
56  */
57 void trade_post_inventory(void);
58 
59 /**
60  * @ingroup trade_log
61  * @brief Free tradelog memory.
62  *
63  * @callgraph
64  */
65 void destroy_trade_log(void);
66 
67 #ifdef __cplusplus
68 } // extern "C"
69 #endif
70 
71 #endif
72