using System; using System.Collections.Generic; using System.Threading.Tasks; using Wino.Core.Domain.Entities.Shared; using Wino.Core.Domain.Enums; namespace Wino.Core.Domain.Interfaces; /// /// Service for managing keyboard shortcuts for mail operations. /// public interface IKeyboardShortcutService { /// /// Gets all available keyboard shortcuts. /// /// Collection of keyboard shortcuts. Task> GetKeyboardShortcutsAsync(); /// /// Gets enabled keyboard shortcuts only. /// /// Collection of enabled keyboard shortcuts. Task> GetEnabledKeyboardShortcutsAsync(); /// /// Creates or updates a keyboard shortcut. /// /// The keyboard shortcut to save. /// The saved keyboard shortcut. Task SaveKeyboardShortcutAsync(KeyboardShortcut shortcut); /// /// Deletes a keyboard shortcut. /// /// The ID of the shortcut to delete. Task DeleteKeyboardShortcutAsync(Guid shortcutId); /// /// Gets the mail operation for the given key combination. /// /// The pressed key. /// The modifier keys pressed. /// The mail operation if found, otherwise null. Task GetMailOperationForKeyAsync(string key, ModifierKeys modifierKeys); /// /// Checks if a key combination is already assigned to another shortcut. /// /// The key to check. /// The modifier keys to check. /// Optional ID to exclude from the check (for updates). /// True if the combination is already used, false otherwise. Task IsKeyCombinationInUseAsync(string key, ModifierKeys modifierKeys, Guid? excludeShortcutId = null); /// /// Creates default keyboard shortcuts for common mail operations. /// Task CreateDefaultShortcutsAsync(); /// /// Resets all shortcuts to defaults. /// Task ResetToDefaultShortcutsAsync(); }