ingame/armory/gamepad/armory_gamepad.lua:15 -- ARMORY_GAMEPAD_FRAGMENT:RegisterCallback("StateChange", function(oldState, newState)
if newState == SCENE_FRAGMENT_SHOWING then
self.mode = ARMORY_OVERVIEW_MODE
self.selectedBuildData = nil
self:SetCurrentList(self.buildList)
self:RefreshList()
self:SetActiveKeybinds(self.buildKeybindStripDescriptor)
-- Since always defaulting to the overview mode, refresh the list before getting the target data.
local targetData = self.buildList:GetTargetData()
self:RefreshTargetTooltip(self.buildList, targetData)
elseif newState == SCENE_FRAGMENT_SHOWN then
TriggerTutorial(TUTORIAL_TRIGGER_ARMORY_OPENED)
elseif newState == SCENE_FRAGMENT_HIDDEN then
self:ResetTooltips()
end
end)