small scanning fix
This commit is contained in:
@@ -72,7 +72,10 @@ function Aux.buy.SearchButton_onclick()
|
|||||||
Aux.scan.start{
|
Aux.scan.start{
|
||||||
query = search_query,
|
query = search_query,
|
||||||
page = 0,
|
page = 0,
|
||||||
on_page_update = function(page)
|
on_submit_query = function()
|
||||||
|
current_page = nil
|
||||||
|
end,
|
||||||
|
on_page_loaded = function(page)
|
||||||
current_page = page
|
current_page = page
|
||||||
end,
|
end,
|
||||||
on_start_page = function(ok, page, total_pages)
|
on_start_page = function(ok, page, total_pages)
|
||||||
@@ -194,7 +197,10 @@ function find_auction(entry, buyout_mode, express_mode)
|
|||||||
Aux.scan.start{
|
Aux.scan.start{
|
||||||
query = search_query,
|
query = search_query,
|
||||||
page = entry.page ~= current_page and entry.page,
|
page = entry.page ~= current_page and entry.page,
|
||||||
on_page_update = function(page)
|
on_submit_query = function()
|
||||||
|
current_page = nil
|
||||||
|
end,
|
||||||
|
on_page_loaded = function(page)
|
||||||
current_page = page
|
current_page = page
|
||||||
end,
|
end,
|
||||||
on_read_auction = function(ok, i)
|
on_read_auction = function(ok, i)
|
||||||
|
|||||||
@@ -122,12 +122,16 @@ function submit_query(k)
|
|||||||
if state.page then
|
if state.page then
|
||||||
wait_for_callback(state.job.on_start_page, {state.page, state.total_pages}, function()
|
wait_for_callback(state.job.on_start_page, {state.page, state.total_pages}, function()
|
||||||
controller().wait(CanSendAuctionQuery, function()
|
controller().wait(CanSendAuctionQuery, function()
|
||||||
wait_for_results(function()
|
if state.job.on_submit_query then
|
||||||
if state.job.on_page_update then
|
state.job.on_submit_query()
|
||||||
state.job.on_page_update(state.page)
|
|
||||||
end
|
end
|
||||||
wait_for_complete_results(k)
|
wait_for_results(function()
|
||||||
end)
|
wait_for_complete_results(function()
|
||||||
|
if state.job.on_page_loaded then
|
||||||
|
state.job.on_page_loaded(state.page)
|
||||||
|
end
|
||||||
|
k()
|
||||||
|
end)end)
|
||||||
QueryAuctionItems(
|
QueryAuctionItems(
|
||||||
state.job.query.name,
|
state.job.query.name,
|
||||||
state.job.query.min_level,
|
state.job.query.min_level,
|
||||||
|
|||||||
Reference in New Issue
Block a user