Пример #1
0
 public void GainedGamepadFocus()
 {
     RecentlyGainedFocus     = true;
     HoveredSlot             = SlotBounds.First();
     HoveredContentsButton   = null;
     IsNavigatingWithGamepad = true;
 }
Пример #2
0
 public bool TryNavigate(NavigationDirection Direction, NavigationWrappingMode HorizontalWrapping, NavigationWrappingMode VerticalWrapping)
 {
     if (IsGamepadFocused && HoveredSlot == null)
     {
         HoveredSlot             = SlotBounds.First();
         IsNavigatingWithGamepad = HoveredSlot != null;
         return(HoveredSlot != null);
     }
     else if (TryGetSlotNeighbor(HoveredSlot, Direction, HorizontalWrapping, VerticalWrapping, out Rectangle? Neighbor))
     {
         HoveredSlot             = Neighbor.Value;
         IsNavigatingWithGamepad = true;
         return(true);
     }
     else
     {
         return(false);
     }
 }
Пример #3
0
 public void GainedGamepadFocus()
 {
     RecentlyGainedFocus     = true;
     HoveredSlot             = SlotBounds.First().Value[ColumnType.RegularQuality];
     IsNavigatingWithGamepad = true;
 }