Calendar attachments.

This commit is contained in:
Burak Kaan Köse
2026-01-03 23:59:37 +01:00
parent c8ef031e7d
commit 4603b1fb14
20 changed files with 758 additions and 21 deletions
@@ -54,4 +54,28 @@ public interface ICalendarService
/// Gets predefined reminder options in minutes (1 Hour, 30 Min, 15 Min, 5 Min, 1 Min).
/// </summary>
int[] GetPredefinedReminderMinutes();
#region Attachments
/// <summary>
/// Gets all attachments for a calendar event.
/// </summary>
Task<List<CalendarAttachment>> GetAttachmentsAsync(Guid calendarItemId);
/// <summary>
/// Inserts or updates calendar attachments.
/// </summary>
Task InsertOrReplaceAttachmentsAsync(List<CalendarAttachment> attachments);
/// <summary>
/// Marks an attachment as downloaded and updates its local file path.
/// </summary>
Task MarkAttachmentDownloadedAsync(Guid attachmentId, string localFilePath);
/// <summary>
/// Deletes all attachments for a calendar item.
/// </summary>
Task DeleteAttachmentsAsync(Guid calendarItemId);
#endregion
}
@@ -22,4 +22,9 @@ public interface INativeAppService
/// This is used to display WAM broker dialog on running UWP app called by a windowless server code.
/// </summary>
Func<IntPtr> GetCoreWindowHwnd { get; set; }
/// <summary>
/// Gets the folder path where calendar attachments are stored.
/// </summary>
string GetCalendarAttachmentsFolderPath();
}
@@ -2,6 +2,7 @@
using System.Threading;
using System.Threading.Tasks;
using MailKit;
using Wino.Core.Domain.Entities.Calendar;
using Wino.Core.Domain.Entities.Mail;
using Wino.Core.Domain.Models.Folders;
using Wino.Core.Domain.Models.Synchronization;
@@ -46,4 +47,5 @@ public interface IWinoSynchronizerBase : IBaseSynchronizer
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>Search results after downloading missing mail copies from server.</returns>
Task<List<MailCopy>> OnlineSearchAsync(string queryText, List<IMailItemFolder> folders, CancellationToken cancellationToken = default);
Task DownloadCalendarAttachmentAsync(CalendarItem calendarItem, CalendarAttachment attachment, string localFilePath, CancellationToken cancellationToken);
}