ingame/crafting/gamepad/gamepadprovisioner.lua:107 -- GAMEPAD_PROVISIONER_CREATION_SCENE:RegisterCallback("StateChange", function(oldState, newState)
if newState == SCENE_SHOWING then
ZO_Skills_TieSkillInfoHeaderToCraftingSkill(self.control:GetNamedChild("SkillInfo"), GetCraftingInteractionType())
if GetCraftingInteractionType() == CRAFTING_TYPE_PROVISIONING then
TriggerTutorial(TUTORIAL_TRIGGER_PROVISIONING_OPENED)
end
-- Reset provisioning heading within provisioning station
if self.mode == PROVISIONER_MODE_CREATION and self.settings then
self.settings = nil
self:SetDefaultProvisioningSettings()
end
self.control:GetNamedChild("IngredientsBar"):SetHidden(false)
self.resultTooltip:SetHidden(false)
SYSTEMS:GetObject("craftingResults"):SetCraftingTooltip(self.resultTooltip)
self.recipeList.control:SetHidden(false)
self.recipeList:Activate()
KEYBIND_STRIP:RemoveDefaultExit()
KEYBIND_STRIP:AddKeybindButtonGroup(self.mainKeybindStripDescriptor)
ZO_GamepadCraftingUtils_RefreshGenericHeader(self)
ZO_GamepadGenericHeader_Activate(self.header)
-- refresh the recipe details on show, since they were cleared/hidden when the scene hid
-- and we may not have had a change in our list to trigger a refresh
self:RefreshRecipeDetails(self:GetRecipeData())
elseif newState == SCENE_HIDDEN then
self:SetDefaultProvisioningSettings()
ZO_Skills_UntieSkillInfoHeaderToCraftingSkill(self.control:GetNamedChild("SkillInfo"))
SYSTEMS:GetObject("craftingResults"):SetCraftingTooltip(nil)
ZO_GamepadGenericHeader_Deactivate(self.header)
self.recipeList:Deactivate()
self.recipeList.control:SetHidden(true)
-- refresh the recipe details passing nil in to appropriately hide/clear the tooltip and ingredient list
local NO_RECIPE = nil
self:RefreshRecipeDetails(NO_RECIPE)
self.control:GetNamedChild("IngredientsBar"):SetHidden(true)
self.resultTooltip:SetHidden(true)
self:EndRecipePreview()
KEYBIND_STRIP:RemoveKeybindButtonGroup(self.mainKeybindStripDescriptor)
KEYBIND_STRIP:RestoreDefaultExit()
end
end)