comparison libpurple/ft.h @ 29800:0687561104d2

propagate from branch 'im.pidgin.pidgin' (head 29f6b9d81574bfa9235dbd438a8934f06552e368) to branch 'im.pidgin.cpw.malu.ft_thumbnails' (head 92cade199b5a7b1bcb88a6264f672811ed7f9fc6)
author Marcus Lundblad <ml@update.uu.se>
date Sun, 20 Sep 2009 19:57:07 +0000
parents c138390bada8
children c35733244829
comparison
equal deleted inserted replaced
28281:5f97830906bc 29800:0687561104d2
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 void (*add_thumbnail)(PurpleXfer *xfer);
124 } PurpleXferUiOps; 124 } PurpleXferUiOps;
125 125
126 /** 126 /**
127 * A core representation of a file transfer. 127 * A core representation of a file transfer.
128 */ 128 */
176 176
177 PurpleXferUiOps *ui_ops; /**< UI-specific operations. */ 177 PurpleXferUiOps *ui_ops; /**< UI-specific operations. */
178 void *ui_data; /**< UI-specific data. */ 178 void *ui_data; /**< UI-specific data. */
179 179
180 void *data; /**< prpl-specific data. */ 180 void *data; /**< prpl-specific data. */
181
182 gpointer thumbnail_data; /**< thumbnail image */
183 gsize thumbnail_size;
181 }; 184 };
182 185
183 #ifdef __cplusplus 186 #ifdef __cplusplus
184 extern "C" { 187 extern "C" {
185 #endif 188 #endif
682 * 685 *
683 * @since 2.6.0 686 * @since 2.6.0
684 */ 687 */
685 void purple_xfer_prpl_ready(PurpleXfer *xfer); 688 void purple_xfer_prpl_ready(PurpleXfer *xfer);
686 689
690 /**
691 * Gets the thumbnail data for a transfer
692 *
693 * @param xfer The file transfer to get the thumbnail for
694 * @return The thumbnail data, or NULL if there is no thumbnail
695 */
696 const void *purple_xfer_get_thumbnail_data(const PurpleXfer *xfer);
697
698 /**
699 * Gets the thumbnail size for a transfer
700 *
701 * @param xfer The file transfer to get the thumbnail size for
702 * @return The size, in bytes of the file transfer's thumbnail
703 */
704 gsize purple_xfer_get_thumbnail_size(const PurpleXfer *xfer);
705
706
707 /**
708 * Sets the thumbnail data for a transfer
709 *
710 * @param xfer The file transfer to set the data for
711 * @param thumbnail A pointer to the thumbnail data, this will be copied
712 * @param size The size in bytes of the passed in thumbnail data
713 */
714 void purple_xfer_set_thumbnail(PurpleXfer *xfer, gconstpointer thumbnail,
715 gsize size);
716
717 /**
718 * Prepare a thumbnail for a transfer (if the UI supports it)
719 * will be no-op in case the UI doesn't implement thumbnail creation
720 *
721 * @param xfer The file transfer to create a thumbnail for
722 */
723 void purple_xfer_prepare_thumbnail(PurpleXfer *xfer);
724
725
687 /*@}*/ 726 /*@}*/
688 727
689 /**************************************************************************/ 728 /**************************************************************************/
690 /** @name UI Registration Functions */ 729 /** @name UI Registration Functions */
691 /**************************************************************************/ 730 /**************************************************************************/