fix(ui): preserve cropped chat and button faces
This commit is contained in:
parent
d825572e31
commit
accacecafe
7 changed files with 168 additions and 8 deletions
|
|
@ -151,9 +151,10 @@ public sealed class UiButton : UiElement, IUiGlobalTimeListener, IUiDatStateful
|
|||
_resolve = resolve;
|
||||
ClickThrough = false; // buttons are interactive — opt OUT of click-through
|
||||
|
||||
foreach (uint stateId in info.States.Keys)
|
||||
if (stateId != UiStateInfo.DirectStateId)
|
||||
_availableStates.Add(stateId);
|
||||
// Visual transitions can select only states with an actual button face.
|
||||
// Retail layouts commonly declare an empty Normal_pressed descriptor while
|
||||
// supplying art only for Normal/Highlight. Treating that property-only state
|
||||
// as drawable briefly blanks the button during mouse-down.
|
||||
foreach (string stateName in info.StateMedia.Keys)
|
||||
if (UiButtonStateMachine.TryStateId(stateName, out uint stateId))
|
||||
_availableStates.Add(stateId);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue