Mercurial > pidgin.yaz
comparison libpurple/ft.h @ 31637:f2e0b8f38e14
propagate from branch 'im.pidgin.pidgin' (head 69fbc32fd3dfe8ca0979e1c486c3d51eb06088cf)
to branch 'im.pidgin.pidgin.openq' (head 0a02249008d0dad085b600dd65c45a347d1c84aa)
author | SHiNE CsyFeK <csyfek@gmail.com> |
---|---|
date | Sun, 07 Nov 2010 04:48:56 +0000 |
parents | 1cdae196aac8 |
children | 44f53d3fc54f |
comparison
equal
deleted
inserted
replaced
31636:35224e759210 | 31637:f2e0b8f38e14 |
---|---|
56 PURPLE_XFER_STATUS_UNKNOWN = 0, /**< Unknown, the xfer may be null. */ | 56 PURPLE_XFER_STATUS_UNKNOWN = 0, /**< Unknown, the xfer may be null. */ |
57 PURPLE_XFER_STATUS_NOT_STARTED, /**< It hasn't started yet. */ | 57 PURPLE_XFER_STATUS_NOT_STARTED, /**< It hasn't started yet. */ |
58 PURPLE_XFER_STATUS_ACCEPTED, /**< Receive accepted, but destination file not selected yet */ | 58 PURPLE_XFER_STATUS_ACCEPTED, /**< Receive accepted, but destination file not selected yet */ |
59 PURPLE_XFER_STATUS_STARTED, /**< purple_xfer_start has been called. */ | 59 PURPLE_XFER_STATUS_STARTED, /**< purple_xfer_start has been called. */ |
60 PURPLE_XFER_STATUS_DONE, /**< The xfer completed successfully. */ | 60 PURPLE_XFER_STATUS_DONE, /**< The xfer completed successfully. */ |
61 PURPLE_XFER_STATUS_CANCEL_LOCAL, /**< The xfer was canceled by us. */ | 61 PURPLE_XFER_STATUS_CANCEL_LOCAL, /**< The xfer was cancelled by us. */ |
62 PURPLE_XFER_STATUS_CANCEL_REMOTE /**< The xfer was canceled by the other end, or we couldn't connect. */ | 62 PURPLE_XFER_STATUS_CANCEL_REMOTE /**< The xfer was cancelled by the other end, or we couldn't connect. */ |
63 } PurpleXferStatusType; | 63 } PurpleXferStatusType; |
64 | 64 |
65 /** | 65 /** |
66 * File transfer UI operations. | 66 * File transfer UI operations. |
67 * | 67 * |
118 * | 118 * |
119 * @since 2.6.0 | 119 * @since 2.6.0 |
120 */ | 120 */ |
121 void (*data_not_sent)(PurpleXfer *xfer, const guchar *buffer, gsize size); | 121 void (*data_not_sent)(PurpleXfer *xfer, const guchar *buffer, gsize size); |
122 | 122 |
123 void (*_purple_reserved1)(void); | 123 /** |
124 * Op to create a thumbnail image for a file transfer | |
125 * | |
126 * @param xfer The file transfer structure | |
127 */ | |
128 void (*add_thumbnail)(PurpleXfer *xfer, const gchar *formats); | |
124 } PurpleXferUiOps; | 129 } PurpleXferUiOps; |
125 | 130 |
126 /** | 131 /** |
127 * A core representation of a file transfer. | 132 * A core representation of a file transfer. |
128 */ | 133 */ |
297 * @return The status. | 302 * @return The status. |
298 */ | 303 */ |
299 PurpleXferStatusType purple_xfer_get_status(const PurpleXfer *xfer); | 304 PurpleXferStatusType purple_xfer_get_status(const PurpleXfer *xfer); |
300 | 305 |
301 /** | 306 /** |
302 * Returns true if the file transfer was canceled. | 307 * Returns true if the file transfer was cancelled. |
303 * | 308 * |
304 * @param xfer The file transfer. | 309 * @param xfer The file transfer. |
305 * | 310 * |
306 * @return Whether or not the transfer was canceled. | 311 * @return Whether or not the transfer was cancelled. |
312 * FIXME: This should be renamed using cancelled for 3.0.0. | |
307 */ | 313 */ |
308 gboolean purple_xfer_is_canceled(const PurpleXfer *xfer); | 314 gboolean purple_xfer_is_canceled(const PurpleXfer *xfer); |
309 | 315 |
310 /** | 316 /** |
311 * Returns the completed state for a file transfer. | 317 * Returns the completed state for a file transfer. |
685 * | 691 * |
686 * @since 2.6.0 | 692 * @since 2.6.0 |
687 */ | 693 */ |
688 void purple_xfer_prpl_ready(PurpleXfer *xfer); | 694 void purple_xfer_prpl_ready(PurpleXfer *xfer); |
689 | 695 |
696 /** | |
697 * Gets the thumbnail data for a transfer | |
698 * | |
699 * @param xfer The file transfer to get the thumbnail for | |
700 * @param len If not @c NULL, the length of the thumbnail data returned | |
701 * will be set in the location pointed to by this. | |
702 * @return The thumbnail data, or NULL if there is no thumbnail | |
703 * @since 2.7.0 | |
704 */ | |
705 gconstpointer purple_xfer_get_thumbnail(const PurpleXfer *xfer, gsize *len); | |
706 | |
707 /** | |
708 * Gets the mimetype of the thumbnail preview for a transfer | |
709 * | |
710 * @param xfer The file transfer to get the mimetype for | |
711 * @return The mimetype of the thumbnail, or @c NULL if not thumbnail is set | |
712 * @since 2.7.0 | |
713 */ | |
714 const gchar *purple_xfer_get_thumbnail_mimetype(const PurpleXfer *xfer); | |
715 | |
716 | |
717 /** | |
718 * Sets the thumbnail data for a transfer | |
719 * | |
720 * @param xfer The file transfer to set the data for | |
721 * @param thumbnail A pointer to the thumbnail data, this will be copied | |
722 * @param size The size in bytes of the passed in thumbnail data | |
723 * @param mimetype The mimetype of the generated thumbnail | |
724 * @since 2.7.0 | |
725 */ | |
726 void purple_xfer_set_thumbnail(PurpleXfer *xfer, gconstpointer thumbnail, | |
727 gsize size, const gchar *mimetype); | |
728 | |
729 /** | |
730 * Prepare a thumbnail for a transfer (if the UI supports it) | |
731 * will be no-op in case the UI doesn't implement thumbnail creation | |
732 * | |
733 * @param xfer The file transfer to create a thumbnail for | |
734 * @param formats A comma-separated list of mimetypes for image formats | |
735 * the protocols can use for thumbnails. | |
736 * @since 2.7.0 | |
737 */ | |
738 void purple_xfer_prepare_thumbnail(PurpleXfer *xfer, const gchar *formats); | |
739 | |
740 | |
690 /*@}*/ | 741 /*@}*/ |
691 | 742 |
692 /**************************************************************************/ | 743 /**************************************************************************/ |
693 /** @name UI Registration Functions */ | 744 /** @name UI Registration Functions */ |
694 /**************************************************************************/ | 745 /**************************************************************************/ |