added a module system
This commit is contained in:
+18
-7
@@ -125,13 +125,24 @@ function private.update_auction_listing()
|
||||
record = auction_record,
|
||||
})
|
||||
end
|
||||
sort(auction_rows, function(a, b) return Aux.sort.multi_lt(
|
||||
a.record.unit_buyout_price == 0 and Aux.huge or a.record.unit_buyout_price, b.record.unit_buyout_price == 0 and Aux.huge or b.record.unit_buyout_price,
|
||||
a.record.unit_blizzard_bid, b.record.unit_blizzard_bid,
|
||||
a.record.stack_size, b.record.stack_size,
|
||||
b.record.own and 1 or 0, a.record.own and 1 or 0,
|
||||
a.record.duration, b.record.duration
|
||||
) end)
|
||||
sort(auction_rows, function(a, b)
|
||||
return Aux.sort.multi_lt(
|
||||
{
|
||||
a.record.unit_buyout_price == 0 and Aux.huge or a.record.unit_buyout_price,
|
||||
a.record.unit_blizzard_bid,
|
||||
a.record.stack_size,
|
||||
b.record.own and 1 or 0,
|
||||
a.record.duration,
|
||||
},
|
||||
{
|
||||
b.record.unit_buyout_price == 0 and Aux.huge or b.record.unit_buyout_price,
|
||||
b.record.unit_blizzard_bid,
|
||||
b.record.stack_size,
|
||||
a.record.own and 1 or 0,
|
||||
b.record.duration,
|
||||
}
|
||||
)
|
||||
end)
|
||||
end
|
||||
private.auction_listing:SetData(auction_rows)
|
||||
end
|
||||
|
||||
@@ -78,6 +78,7 @@ function Aux.post_frame.create_frames(private, public)
|
||||
{ name='Buy/ea', width=.23, align='RIGHT' },
|
||||
{ name='Buy Pct', width=.12, align='CENTER' }
|
||||
})
|
||||
private.auction_listing:EnableSorting(false)
|
||||
private.auction_listing:DisableSelection(true)
|
||||
private.auction_listing:SetHandler('OnClick', function(table, row_data, column, button)
|
||||
local column_index = Aux.util.index_of(column, column.row.cols)
|
||||
|
||||
@@ -629,8 +629,9 @@ function Aux.search_frame.create_frames(private, public)
|
||||
}
|
||||
|
||||
private.recent_searches_listing = Aux.listing.CreateScrollingTable(AuxSearchFrameSavedRecent)
|
||||
private.recent_searches_listing:DisableSelection(true)
|
||||
private.recent_searches_listing:SetColInfo({{name='Recent Searches', width=1}})
|
||||
private.recent_searches_listing:EnableSorting(false)
|
||||
private.recent_searches_listing:DisableSelection(true)
|
||||
private.recent_searches_listing:SetHandler('OnClick', handlers.OnClick)
|
||||
private.recent_searches_listing:SetHandler('OnEnter', handlers.OnEnter)
|
||||
private.recent_searches_listing:SetHandler('OnLeave', handlers.OnLeave)
|
||||
@@ -638,8 +639,9 @@ function Aux.search_frame.create_frames(private, public)
|
||||
Aux.gui.vertical_line(AuxSearchFrameSaved, 379)
|
||||
|
||||
private.favorite_searches_listing = Aux.listing.CreateScrollingTable(AuxSearchFrameSavedFavorite)
|
||||
private.favorite_searches_listing:DisableSelection(true)
|
||||
private.favorite_searches_listing:SetColInfo({{name='Favorite Searches', width=1}})
|
||||
private.favorite_searches_listing:EnableSorting(false)
|
||||
private.favorite_searches_listing:DisableSelection(true)
|
||||
private.favorite_searches_listing:SetHandler('OnClick', handlers.OnClick)
|
||||
private.favorite_searches_listing:SetHandler('OnEnter', handlers.OnEnter)
|
||||
private.favorite_searches_listing:SetHandler('OnLeave', handlers.OnLeave)
|
||||
|
||||
Reference in New Issue
Block a user