Most gamepad stuff gets initialized deferred means it is not loaded until shown first time. So if you add or hook there it will throw nil errors or get insecure code due to addons adding code before all was loaded properly (inventory at keyboard e.g. often was causing this if you tried to change it before it was initialized properly). ZOs added hook functions like SecurePostHook to circumvent this at keyboard stuff, hopefully at gamepad code too.
code gets tainted if you hook or add into it before it was loaded properly. try to use SecurePostHook at dialog functions to make your hooks secure, or add a ZO_PostHookHandler on the OnShow or OnEffectivelyShown (dialogs control) then hide the dialog directly and show your own dialog. Maybe it will make the original load, make all secure and then your dialogs can work afterwards. Could maybe make it flicker once but after that you maybe are able to replace the complete dialogs without getting insecure errors.
|