/// <summary> /// Adds entry to recently used stickers list. /// </summary> /// <since_tizen> 10 </since_tizen> /// <feature>http://tizen.org/feature/ui_service.sticker</feature> /// <param name="data">The sticker data class</param> /// <exception cref="NotSupportedException">The required feature is not supported.</exception> /// <exception cref="ArgumentException">This exception can be due to an invalid parameter.</exception> /// <exception cref="InvalidOperationException">This exception can be due to operation failed.</exception> public static void AddRecentData(StickerData data) { ErrorCode error = StickerConsumerAddRecentData(_handle, data.SafeStickerDataHandle); if (error != ErrorCode.None) { Log.Error(LogTag, "AddRecentData Failed with error " + error); throw ExceptionFactory.CreateException(error); } }
/// <summary> /// Deletes a sticker data in the sticker database. /// </summary> /// <since_tizen> 10 </since_tizen> /// <feature>http://tizen.org/feature/ui_service.sticker</feature> /// <param name="data">The sticker data to be deleted.</param> /// <exception cref="NotSupportedException">The required feature is not supported.</exception> /// <exception cref="ArgumentException">This exception can be due to an invalid parameter.</exception> /// <exception cref="InvalidOperationException">This exception can be due to operation failed.</exception> public static void DeleteData(StickerData data) { ErrorCode error = StickerProviderDeleteData(_handle, data.SafeStickerDataHandle); if (error != ErrorCode.None) { Log.Error(LogTag, "DeleteData Failed with error " + error); throw ExceptionFactory.CreateException(error); } }
/// <summary> /// Gets recently used stickers list. /// The most recently used stickers are delivered in order. /// </summary> /// <since_tizen> 10 </since_tizen> /// <feature>http://tizen.org/feature/ui_service.sticker</feature> /// <param name="count">The number of stickers that you want to receive.</param> /// <exception cref="NotSupportedException">The required feature is not supported.</exception> /// <exception cref="ArgumentException">This exception can be due to an invalid parameter.</exception> /// <exception cref="InvalidOperationException">This exception can be due to operation failed.</exception> public static IEnumerable <StickerData> GetRecentStickers(int count) { var stickers = new List <StickerData>(); StickerConsumerDataForeachCallback _dataForeachDelegate = (IntPtr stickerData, IntPtr userData) => { StickerData data = new StickerData(stickerData); stickers.Add(data); }; ErrorCode error = StickerConsumerGetRecentDataList(_handle, count, out var result, _dataForeachDelegate, IntPtr.Zero); if (error != ErrorCode.None) { Log.Error(LogTag, "GetRecentStickers Failed with error " + error); throw ExceptionFactory.CreateException(error); } return(stickers); }
internal DeletedEventArgs(IntPtr data) { _data = new StickerData(data); }
internal InsertedEventArgs(IntPtr data) { _data = new StickerData(data); }