post right click instead of double click for stack change

This commit is contained in:
Simon Hirsig
2018-09-08 17:01:25 +02:00
parent 5e8f171f40
commit 0f7048787c
+6 -10
View File
@@ -85,17 +85,15 @@ bid_listing:SetSelection(function(data)
return data.record == get_bid_selection() or data.record.historical_value and get_bid_selection() and get_bid_selection().historical_value
end)
bid_listing:SetHandler('OnClick', function(table, row_data, column, button)
if row_data.record == get_bid_selection() or row_data.record.historical_value and get_bid_selection() and get_bid_selection().historical_value then
if button == 'RightButton' then
stack_size_slider:SetValue(row_data.record.stack_size)
elseif row_data.record == get_bid_selection() or row_data.record.historical_value and get_bid_selection() and get_bid_selection().historical_value then
set_bid_selection()
else
set_bid_selection(row_data.record)
end
refresh = true
end)
bid_listing:SetHandler('OnDoubleClick', function(table, row_data, column, button)
stack_size_slider:SetValue(row_data.record.stack_size)
refresh = true
end)
buyout_listing = listing.new(frame.buyout_listing)
buyout_listing:SetColInfo{
@@ -109,17 +107,15 @@ buyout_listing:SetSelection(function(data)
return data.record == get_buyout_selection() or data.record.historical_value and get_buyout_selection() and get_buyout_selection().historical_value
end)
buyout_listing:SetHandler('OnClick', function(table, row_data, column, button)
if row_data.record == get_buyout_selection() or row_data.record.historical_value and get_buyout_selection() and get_buyout_selection().historical_value then
if button == 'RightButton' then
stack_size_slider:SetValue(row_data.record.stack_size)
elseif row_data.record == get_buyout_selection() or row_data.record.historical_value and get_buyout_selection() and get_buyout_selection().historical_value then
set_buyout_selection()
else
set_buyout_selection(row_data.record)
end
refresh = true
end)
buyout_listing:SetHandler('OnDoubleClick', function(table, row_data, column, button)
stack_size_slider:SetValue(row_data.record.stack_size)
refresh = true
end)
do
status_bar = gui.status_bar(frame)