ingame/inventory/inventory.lua:2714 -- houseBankScene:RegisterCallback("StateChange", function(oldState, newState)
if newState == SCENE_SHOWING then
--initialize the slots and banking bag fresh here since there are many different house bank bags and only one is active at a time
local inventory = self.inventories[INVENTORY_HOUSE_BANK]
local bankingBag = GetBankingBag()
inventory.slots = { [bankingBag] = {} }
inventory.backingBags = { bankingBag }
houseBankFragmentBar:SelectFragment(SI_BANK_WITHDRAW)
self:RefreshAllInventorySlots(INVENTORY_HOUSE_BANK)
self:UpdateFreeSlots(INVENTORY_HOUSE_BANK)
self:UpdateFreeSlots(INVENTORY_BACKPACK)
TriggerTutorial(TUTORIAL_TRIGGER_HOME_STORAGE_OPENED)
elseif newState == SCENE_HIDDEN then
ZO_InventorySlot_RemoveMouseOverKeybinds()
houseBankFragmentBar:Clear()
--Wipe out the inventory slot data and connection to a bag
local inventory = self.inventories[INVENTORY_HOUSE_BANK]
inventory.slots = nil
inventory.backingBags = nil
inventory.hasAnyQuickSlottableItems = nil
end
end)