| cmds.h | | cmds.h | |
| | | | |
| skipping to change at line 33 | | skipping to change at line 33 | |
| #ifndef _PURPLE_CMDS_H_ | | #ifndef _PURPLE_CMDS_H_ | |
| #define _PURPLE_CMDS_H_ | | #define _PURPLE_CMDS_H_ | |
| | | | |
| #include "conversation.h" | | #include "conversation.h" | |
| | | | |
| /**************************************************************************
/ | | /**************************************************************************
/ | |
| /** @name Structures *
/ | | /** @name Structures *
/ | |
| /**************************************************************************
/ | | /**************************************************************************
/ | |
| /*@{*/ | | /*@{*/ | |
| | | | |
|
| typedef enum _PurpleCmdPriority PurpleCmdPriority; | | | |
| typedef enum _PurpleCmdFlag PurpleCmdFlag; | | | |
| typedef enum _PurpleCmdStatus PurpleCmdStatus; | | | |
| typedef enum _PurpleCmdRet PurpleCmdRet; | | | |
| | | | |
| enum _PurpleCmdStatus { | | enum _PurpleCmdStatus { | |
| PURPLE_CMD_STATUS_OK, | | PURPLE_CMD_STATUS_OK, | |
| PURPLE_CMD_STATUS_FAILED, | | PURPLE_CMD_STATUS_FAILED, | |
| PURPLE_CMD_STATUS_NOT_FOUND, | | PURPLE_CMD_STATUS_NOT_FOUND, | |
| PURPLE_CMD_STATUS_WRONG_ARGS, | | PURPLE_CMD_STATUS_WRONG_ARGS, | |
| PURPLE_CMD_STATUS_WRONG_PRPL, | | PURPLE_CMD_STATUS_WRONG_PRPL, | |
| PURPLE_CMD_STATUS_WRONG_TYPE, | | PURPLE_CMD_STATUS_WRONG_TYPE, | |
| }; | | }; | |
| | | | |
| enum _PurpleCmdRet { | | enum _PurpleCmdRet { | |
| PURPLE_CMD_RET_OK, /**< Everything's okay. Don't look for anot
her command to call. */ | | PURPLE_CMD_RET_OK, /**< Everything's okay. Don't look for anot
her command to call. */ | |
| PURPLE_CMD_RET_FAILED, /**< The command failed, but stop looking.*
/ | | PURPLE_CMD_RET_FAILED, /**< The command failed, but stop looking.*
/ | |
| PURPLE_CMD_RET_CONTINUE, /**< Continue, looking for other commands w
ith the same name to call. */ | | PURPLE_CMD_RET_CONTINUE, /**< Continue, looking for other commands w
ith the same name to call. */ | |
| }; | | }; | |
| | | | |
| #define PURPLE_CMD_FUNC(func) ((PurpleCmdFunc)func) | | #define PURPLE_CMD_FUNC(func) ((PurpleCmdFunc)func) | |
| | | | |
|
| typedef PurpleCmdRet (*PurpleCmdFunc)(PurpleConversation *, const gchar *cm
d, | | typedef enum _PurpleCmdRet (*PurpleCmdFunc)(PurpleConversation *, const gch
ar *cmd, | |
| gchar **args, gchar **error, void *data); | | gchar **args, gchar **error, void *data); | |
| typedef guint PurpleCmdId; | | typedef guint PurpleCmdId; | |
| | | | |
| enum _PurpleCmdPriority { | | enum _PurpleCmdPriority { | |
| PURPLE_CMD_P_VERY_LOW = -1000, | | PURPLE_CMD_P_VERY_LOW = -1000, | |
| PURPLE_CMD_P_LOW = 0, | | PURPLE_CMD_P_LOW = 0, | |
| PURPLE_CMD_P_DEFAULT = 1000, | | PURPLE_CMD_P_DEFAULT = 1000, | |
| PURPLE_CMD_P_PRPL = 2000, | | PURPLE_CMD_P_PRPL = 2000, | |
| PURPLE_CMD_P_PLUGIN = 3000, | | PURPLE_CMD_P_PLUGIN = 3000, | |
| PURPLE_CMD_P_ALIAS = 4000, | | PURPLE_CMD_P_ALIAS = 4000, | |
| | | | |
| skipping to change at line 87 | | skipping to change at line 82 | |
| /** Command is usable in IMs. */ | | /** Command is usable in IMs. */ | |
| PURPLE_CMD_FLAG_IM = 0x01, | | PURPLE_CMD_FLAG_IM = 0x01, | |
| /** Command is usable in multi-user chats. */ | | /** Command is usable in multi-user chats. */ | |
| PURPLE_CMD_FLAG_CHAT = 0x02, | | PURPLE_CMD_FLAG_CHAT = 0x02, | |
| /** Command is usable only for a particular prpl. */ | | /** Command is usable only for a particular prpl. */ | |
| PURPLE_CMD_FLAG_PRPL_ONLY = 0x04, | | PURPLE_CMD_FLAG_PRPL_ONLY = 0x04, | |
| /** Incorrect arguments to this command should be accepted anyway. *
/ | | /** Incorrect arguments to this command should be accepted anyway. *
/ | |
| PURPLE_CMD_FLAG_ALLOW_WRONG_ARGS = 0x08, | | PURPLE_CMD_FLAG_ALLOW_WRONG_ARGS = 0x08, | |
| }; | | }; | |
| | | | |
|
| | | typedef enum _PurpleCmdPriority PurpleCmdPriority; | |
| | | typedef enum _PurpleCmdFlag PurpleCmdFlag; | |
| | | typedef enum _PurpleCmdStatus PurpleCmdStatus; | |
| | | typedef enum _PurpleCmdRet PurpleCmdRet; | |
| | | | |
| /*@}*/ | | /*@}*/ | |
| | | | |
| #ifdef __cplusplus | | #ifdef __cplusplus | |
| extern "C" { | | extern "C" { | |
| #endif | | #endif | |
| | | | |
| /**************************************************************************
/ | | /**************************************************************************
/ | |
| /** @name Commands API *
/ | | /** @name Commands API *
/ | |
| /**************************************************************************
/ | | /**************************************************************************
/ | |
| /*@{*/ | | /*@{*/ | |
| | | | |
End of changes. 3 change blocks. |
| 6 lines changed or deleted | | 6 lines changed or added | |
|