ingame/crafting/gamepad/enchanting_gamepad.lua:135 -- GAMEPAD_ENCHANTING_MODE_SCENE_ROOT:RegisterCallback("StateChange", function(oldState, newState)
if newState == SCENE_SHOWING then
KEYBIND_STRIP:AddKeybindButtonGroup(self.keybindModeStripDescriptor)
self:SetEnchantingMode(ENCHANTING_MODE_NONE)
self.modeList:Activate()
local titleString = ZO_GamepadCraftingUtils_GetLineNameForCraftingType(CRAFTING_TYPE_ENCHANTING)
ZO_GamepadCraftingUtils_SetupGenericHeader(self, titleString)
ZO_GamepadCraftingUtils_RefreshGenericHeader(self)
elseif newState == SCENE_HIDDEN then
KEYBIND_STRIP:RemoveKeybindButtonGroup(self.keybindModeStripDescriptor)
GAMEPAD_CRAFTING_RESULTS:SetCraftingTooltip(nil)
self.modeList:Deactivate()
if self.enchantingMode ~= ENCHANTING_MODE_NONE then
self.inventory:Deactivate()
end
end
end)