some open code refactoring, changed shortcut from alt-leftclick to right click

This commit is contained in:
Manuel Simon Hirsig
2016-02-20 08:05:10 +01:00
parent 44080024a7
commit c43808112d
2 changed files with 22 additions and 11 deletions
+4 -6
View File
@@ -1,6 +1,6 @@
Postal.open = {}
local wait_for_update, open, process, inventory_count
local wait_for_update, open, process, inventory_count, stop
local controller = (function()
local controller
@@ -15,17 +15,15 @@ function wait_for_update(k)
end
function Postal.open.start(selected, callback)
Postal.control.on_next_update(function()
controller().wait(function()
process(selected, function()
callback()
callback()
end)
end)
end
function Postal.open.stop()
Postal.control.on_next_update(function()
controller().reset()
end)
controller().wait(function() end)
end
function process(selected, k)