@@ -37,18 +37,13 @@ public class OutfitSlotPresenter : IDisposable
3737 public event Action < OutfitItem > ? OnEquipRequested ;
3838 public event Action < OutfitItem > ? OnPreviewRequested ;
3939
40- public bool HasThumbnail ( )
41- {
42- return currentThumbnail != null ;
43- }
44-
4540 public readonly int slotIndex ;
4641
4742 private readonly OutfitSlotView view ;
4843 private readonly HoverHandler hoverHandler ;
4944 private readonly IAvatarScreenshotService screenshotService ;
5045 private CancellationTokenSource cts = new ( ) ;
51-
46+
5247 private bool isHovered ;
5348 private bool isForcedHover ;
5449 private OutfitSlotState currentState ;
@@ -67,16 +62,17 @@ public OutfitSlotPresenter( OutfitSlotView view,
6762 view . OnDeleteClicked += HandleDeleteClicked ;
6863 view . OnEquipClicked += HandleEquipClicked ;
6964 view . OnPreviewClicked += HandlePreviewClicked ;
70-
65+
7166 hoverHandler = view . hoverHandler ;
7267 hoverHandler . OnHoverEntered += OnHoverEntered ;
7368 hoverHandler . OnHoverExited += OnHoverExited ;
7469 }
7570
76- public OutfitItem ? GetOutfitData ( )
77- {
78- return currentOutfitData ;
79- }
71+ public bool HasThumbnail ( ) =>
72+ currentThumbnail != null ;
73+
74+ public OutfitItem ? GetOutfitData ( ) =>
75+ currentOutfitData ;
8076
8177 private void HandleSaveClicked ( )
8278 {
@@ -176,6 +172,13 @@ public void SetEquipLoading(bool loading) =>
176172 public void SetHoverEnabled ( bool isEnabled ) =>
177173 view . SetHoverEnabled ( isEnabled ) ;
178174
175+ public void ResetHoverState ( )
176+ {
177+ isHovered = false ;
178+ view . ResetHoverState ( ) ;
179+ UpdateView ( ) ;
180+ }
181+
179182 private void SetState ( OutfitSlotState newState , OutfitItem ? item = null )
180183 {
181184 currentState = newState ;
@@ -185,8 +188,8 @@ private void SetState(OutfitSlotState newState, OutfitItem? item = null)
185188
186189 private void UpdateView ( )
187190 {
188- bool effectiveHover = isHovered || isForcedHover ;
189-
191+ bool effectiveHover = isHovered || isForcedHover ;
192+
190193 switch ( currentState )
191194 {
192195 case OutfitSlotState . Empty : view . ShowEmptyState ( isHovered ) ; break ;
@@ -275,4 +278,4 @@ public void PlaySaveOutfitSound()
275278 view . PlaySaveOutfitSound ( ) ;
276279 }
277280 }
278- }
281+ }
0 commit comments