X-Git-Url: http://git.maemo.org/git/?p=python-purple;a=blobdiff_plain;f=notify_cbs.pxd;h=f23bb0e264faf50f69e78589c81f6c78d404d230;hp=ed6dbd6fd2e126e214a14c61150f88911e5f8699;hb=04a67111cf9c4610630188dc9b4200c79e0640b2;hpb=f0ff8c3ffbd828fbdc0963c8c4744c94363f40a7 diff --git a/notify_cbs.pxd b/notify_cbs.pxd index ed6dbd6..f23bb0e 100644 --- a/notify_cbs.pxd +++ b/notify_cbs.pxd @@ -19,86 +19,90 @@ cimport purple -notify_cbs = {} - cdef extern from *: ctypedef char const_char "const char" ctypedef int size_t -cdef void *notify_message (notify.PurpleNotifyMsgType type, const_char *title, - const_char *primary, const_char *secondary): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", "notify-message\n") - try: - (notify_cbs["notify-message"])("notify-message: TODO") - except KeyError: - pass +notify_cbs = {} + +cdef void *notify_message(notify.PurpleNotifyMsgType type, \ + const_char *title, const_char *primary, const_char *secondary): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "notify-message\n") + if notify_cbs.has_key("notif-message"): + ( notify_cbs["notify-message"])("notify-message: TODO") -cdef void *notify_email (connection.PurpleConnection *gc, const_char *subject, - const_char *_from, const_char *to, const_char *url): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", "notify-email\n") - try: - (notify_cbs["notify-email"])("notify-email: TODO") - except KeyError: - pass +cdef void *notify_email(connection.PurpleConnection *gc, \ + const_char *subject, const_char *_from, const_char *to, \ + const_char *url): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "notify-email\n") + if notify_cbs.has_key("notify-email"): + ( notify_cbs["notify-email"])("notify-email: TODO") -cdef void *notify_emails (connection.PurpleConnection *gc, size_t count, - glib.gboolean detailed, const_char **subjects, - const_char **froms, const_char **tos, - const_char **urls): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", "notify-emails\n") - try: - (notify_cbs["notify-emails"])("notify-emails: TODO") - except KeyError: - pass +cdef void *notify_emails(connection.PurpleConnection *gc, size_t count, \ + glib.gboolean detailed, const_char **subjects, \ + const_char **froms, const_char **tos, const_char **urls): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "notify-emails\n") + if notify_cbs.has_key("notify-emails"): + ( notify_cbs["notify-emails"])("notify-emails: TODO") -cdef void *notify_formatted (const_char *title, const_char *primary, - const_char *secondary, const_char *text): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", "notify-formatted\n") - try: - (notify_cbs["notify-formatted"])("notify-formatted: TODO") - except KeyError: - pass +cdef void *notify_formatted(const_char *title, const_char *primary, \ + const_char *secondary, const_char *text): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "notify-formatted\n") + if notify_cbs.has_key("notify-formatted"): + ( notify_cbs["notify-formatted"])("notify-formatted: TODO") -cdef void *notify_searchresults (connection.PurpleConnection *gc, - const_char *title, const_char *primary, - const_char *secondary, - notify.PurpleNotifySearchResults *results, - glib.gpointer user_data): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", - "notify-searchresults\n") - try: - (notify_cbs["notify-searchresults"])("notify-searchresults: TODO") - except KeyError: - pass +cdef void *notify_searchresults(connection.PurpleConnection *gc, \ + const_char *title, const_char *primary, const_char *secondary, \ + notify.PurpleNotifySearchResults *results, glib.gpointer user_data): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "notify-searchresults\n") + if notify_cbs.has_key("notify-searchresults"): + ( notify_cbs["notify-searchresults"])("notify-searchresults: TODO") -cdef void notify_searchresults_new_rows (connection.PurpleConnection *gc, - notify.PurpleNotifySearchResults *results, - void *data): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", - "notify-searchresults-new-rows\n") - try: - (notify_cbs["notify-searchresults-new-rows"])("notify-searchresults-new-rows: TODO") - except KeyError: - pass +cdef void notify_searchresults_new_rows(connection.PurpleConnection *gc, \ + notify.PurpleNotifySearchResults *results, void *data): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "notify-searchresults-new-rows\n") + if notify_cbs.has_key("notify-searchresults-new-rows"): + ( notify_cbs["notify-searchresults-new-rows"])("notify-searchresults-new-rows: TODO") -cdef void *notify_userinfo (connection.PurpleConnection *gc, const_char *who, - notify.PurpleNotifyUserInfo *user_info): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", "notify-userinfo\n") - try: - (notify_cbs["notify-userinfo"])("notify-userinfo: TODO") - except KeyError: - pass +cdef void *notify_userinfo(connection.PurpleConnection *gc, const_char *who, \ + notify.PurpleNotifyUserInfo *user_info): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "notify-userinfo\n") + if notify_cbs.has_key("notify-userinfo"): + ( notify_cbs["notify-userinfo"])("notify-userinfo: TODO") -cdef void *notify_uri (const_char *uri): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", "notify-uri\n") - try: - (notify_cbs["notify-uri"])("notify-uri: TODO") - except KeyError: - pass +cdef void *notify_uri(const_char *uri): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "notify-uri\n") + if notify_cbs.has_key("notify-uri"): + ( notify_cbs["notify-uri"])("notify-uri: TODO") -cdef void close_notify (notify.PurpleNotifyType type, void *ui_handle): - debug.c_purple_debug(debug.PURPLE_DEBUG_INFO, "notify", "close-notify\n") - try: - (notify_cbs["close-notify"])("close-notify: TODO") - except KeyError: - pass +cdef void close_notify(notify.PurpleNotifyType type, void *ui_handle): + """ + TODO + """ + debug.purple_debug_info("notify", "%s", "close-notify\n") + if notify_cbs.has_key("close-notify"): + ( notify_cbs["close-notify"])("close-notify: TODO")