Fix inheritence of IMenuItemClickedArgs (#1863)

This commit is contained in:
Blair 2024-06-29 19:28:56 +10:00 committed by GitHub
parent 0f6f037f81
commit 0604caad4e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -40,7 +40,7 @@ internal sealed unsafe class MenuItemClickedArgs : MenuArgs, IMenuItemClickedArg
/// <summary>
/// An interface representing the callback args used when a menu item is clicked.
/// </summary>
public interface IMenuItemClickedArgs
public interface IMenuItemClickedArgs : IMenuArgs
{
/// <summary>
/// Opens a submenu with the given name and items.
@ -54,39 +54,4 @@ public interface IMenuItemClickedArgs
/// </summary>
/// <param name="items">The items to display in the submenu.</param>
void OpenSubmenu(IReadOnlyList<IMenuItem> items);
/// <summary>
/// Gets a list of AtkEventInterface pointers associated with the context menu.
/// Only available with <see cref="ContextMenuType.Default"/>.
/// Almost always an agent pointer. You can use this to find out what type of context menu it is.
/// </summary>
/// <exception cref="InvalidOperationException">Thrown when the context menu is not a <see cref="ContextMenuType.Default"/>.</exception>
IReadOnlySet<nint> EventInterfaces { get; }
/// <summary>
/// Gets the name of the addon that opened the context menu.
/// </summary>
string? AddonName { get; }
/// <summary>
/// Gets the memory pointer of the addon that opened the context menu.
/// </summary>
nint AddonPtr { get; }
/// <summary>
/// Gets the memory pointer of the agent that opened the context menu.
/// </summary>
nint AgentPtr { get; }
/// <summary>
/// Gets the type of the context menu.
/// </summary>
ContextMenuType MenuType { get; }
/// <summary>
/// Gets the target info of the context menu. The actual type depends on <see cref="MenuType"/>.
/// <see cref="ContextMenuType.Default"/> signifies a <see cref="MenuTargetDefault"/>.
/// <see cref="ContextMenuType.Inventory"/> signifies a <see cref="MenuTargetInventory"/>.
/// </summary>
MenuTarget Target { get; }
}