fix(ui): restore retail magic shortcut bar
Port the retail horizontal ItemList empty-slot padding and share UIItem shortcut-number graphics with the status toolbar. Preserve all authored face children on compound DAT buttons so the three-piece Cast control reflows and renders as one complete button. Co-authored-by: OpenAI Codex <codex@openai.com>
This commit is contained in:
parent
0527325b25
commit
e3605672bb
12 changed files with 466 additions and 62 deletions
|
|
@ -36,6 +36,9 @@ public sealed class UiCatalogSlot : UiItemSlot
|
|||
public Action<object>? DragEnded { get; init; }
|
||||
public Action<object>? Dropped { get; init; }
|
||||
|
||||
protected override bool IsShortcutOccupied => EntryId != 0u;
|
||||
public override bool IsEmptySlot => EntryId == 0u;
|
||||
|
||||
public override string? GetTooltipText() => string.IsNullOrWhiteSpace(Label) ? null : Label;
|
||||
|
||||
public override bool IsDragSource => CatalogDragPayload is not null;
|
||||
|
|
@ -102,6 +105,11 @@ public sealed class UiCatalogSlot : UiItemSlot
|
|||
if (CatalogOverlayTexture != 0)
|
||||
ctx.DrawSprite(CatalogOverlayTexture, IconLeft, IconTop, iconWidth, iconHeight, 0f, 0f, 1f, 1f, Vector4.One);
|
||||
|
||||
// Spell favorites are UIElement_UIItems too. Retail's
|
||||
// SpellCastSubMenu::UpdateShortcutOverlays @ 0x004C5BE0 calls the same
|
||||
// SetShortcutNum path used by physical toolbar shortcuts.
|
||||
DrawShortcutOverlay(ctx);
|
||||
|
||||
if (!SelectionBehindContent)
|
||||
DrawSelection(ctx);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue