scanning performance improvement
This commit is contained in:
@@ -778,6 +778,7 @@ function private.refresh_entries()
|
|||||||
private.status_bar:set_text('Scanning auctions...')
|
private.status_bar:set_text('Scanning auctions...')
|
||||||
|
|
||||||
Aux.scan.start{
|
Aux.scan.start{
|
||||||
|
no_wait_owner = true,
|
||||||
queries = { query },
|
queries = { query },
|
||||||
on_page_loaded = function(page, total_pages)
|
on_page_loaded = function(page, total_pages)
|
||||||
private.status_bar:update_status(100 * (page + 1) / total_pages, 0) -- TODO
|
private.status_bar:update_status(100 * (page + 1) / total_pages, 0) -- TODO
|
||||||
|
|||||||
@@ -80,16 +80,19 @@ function wait_for_results(k)
|
|||||||
last_update = GetTime()
|
last_update = GetTime()
|
||||||
end)
|
end)
|
||||||
listener:start()
|
listener:start()
|
||||||
Aux.control.as_soon_as(function() return last_update and GetTime() - last_update > 3 or owner_data_complete end, function()
|
Aux.control.as_soon_as(function() return last_update and GetTime() - last_update > 5 or owner_data_complete end, function()
|
||||||
listener:stop()
|
listener:stop()
|
||||||
ok = true
|
ok = true
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
return controller().wait(function() return ok end, k)
|
return controller().wait(function() return ok end, k)
|
||||||
end
|
end
|
||||||
|
|
||||||
function private.owner_data_complete()
|
function private.owner_data_complete()
|
||||||
|
if state.params.no_wait_owner then
|
||||||
|
return true
|
||||||
|
end
|
||||||
local count, _ = GetNumAuctionItems(current_query().type)
|
local count, _ = GetNumAuctionItems(current_query().type)
|
||||||
for i=1,count do
|
for i=1,count do
|
||||||
local auction_info = Aux.info.auction(i, current_query().type)
|
local auction_info = Aux.info.auction(i, current_query().type)
|
||||||
|
|||||||
Reference in New Issue
Block a user