View Single Post
07/20/15, 03:26 PM   #7
circonian
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 613
One thing I just thought of though:
Lua Code:
  1. BACKPACK_TRADING_HOUSE_LAYOUT_FRAGMENT.layoutData.additionalFilter = function (slot)
  2.             return (slot.quality ~= ITEM_QUALITY_TRASH) and (not slot.stolen) and (not IsItemBound(slot.bagId, slot.slotIndex))
  3.         end
That was a bad idea, don't use it.
It will mess up addons using either of the filtering libraries for the trading house if the library gets loaded first & sets the additional filter and then some other addon changes it. That could of course be fixed, by saving the original additional filter & calling it with the new function, but you'de never be able to remove the changes. Although would that be necessary? Do you ever need to see bound items...well I guess it would be ok.
Lua Code:
  1. local origAdditionalFilter = BACKPACK_TRADING_HOUSE_LAYOUT_FRAGMENT.layoutData.additionalFilter
  2. BACKPACK_TRADING_HOUSE_LAYOUT_FRAGMENT.layoutData.additionalFilter = function (slot)
  3.             return origAdditionalFilter(slot) and (not IsItemBound(slot.bagId, slot.slotIndex))
  4.         end

Last edited by circonian : 07/20/15 at 05:15 PM.
  Reply With Quote