Hello,
I'm handling the DB and profiles of my addon via Ace3 libs, and there is something I'm not sure how to do (if possible at all). This is the relevant code:
Code:
-- DB
self.db = LibStub("AceDB-3.0"):New("MyAddonDB", defaults, true)
-- Profile management
self.profileOptions = LibStub("AceDBOptions-3.0"):GetOptionsTable(self.db)
-- Register configuration options to Ace3
LibStub("AceConfig-3.0"):RegisterOptionsTable("MyAddon", self.options)
LibStub("AceConfig-3.0"):RegisterOptionsTable("MyAddonProfiles", self.profileOptions)
-- Add Configuration options to blizzard UI
self.configPanel = AceConfigDialog:AddToBlizOptions("MyAddon", "MyAddon")
self.configPanel.profilePanel = AceConfigDialog:AddToBlizOptions("MyAddonProfiles", "Profiles", "MyAddon")
This puts the profiles as a sub-menu of my addon in "interface->addons" menu, openned with "+".
I open the config window by:
LibStub("AceConfigDialog-3.0"):Open() which opens it as a separate, movable window.
However, when I open it this way, I don't have the "profiles" management window. I want to have it as a level one tab (similiar to what I see in interface->addons->MyAddon). I've tried to register it to "self.options.args.profiles", but then it is shown as an internal tab. And when I go through interface->addons I see it twice: first one is the addon sub-menu (openned with +), and second in the addons pane, as an internal tab.
How do I make it right?
Thanks