
Create API for other add-ons to use
plusmouse opened this issue ยท 3 comments
Other addons used Atr_SearchAH(ListName, items) - now broken. This was an unofficial way to search for a list of items
Proposed API:
Auctionator.API.v1.Initialise()
Auctionator.API.v1.MultiSearch(terms)
Auctionator.API.v1.ReplaceList(listName, terms) -- Replaces an existing list, or creates a new one
With these functions giving an error if called when the ah isn't open.
Hopefully this will leave us with enough implementation flexibility to completely redo the internal details without changing the API. Changing the API is something we'd like to avoid.
For ATT, only reason it broke was because of:
Was: if AuctionFrame and AuctionFrame:IsShown() then
Now: if AuctionHouseFrame and AuctionHouseFrame:IsShown() then
But the overall string with:
Atr_SelectPane(3);
Atr_SearchAH(L["TITLE"], missingItems, LE_ITEM_CLASS_ARMOR);
and
Atr_SelectPane(3);
Atr_SetSearchText (name);
Atr_Search_Onclick ();
All just simply broke :)