refactoring

This commit is contained in:
Manuel Simon Hirsig
2016-08-26 23:53:43 +02:00
parent 5ac44f13d8
commit ac19eba7c6
4 changed files with 75 additions and 9 deletions
+17 -2
View File
@@ -1,8 +1,23 @@
aux 'core'
event_frame = CreateFrame 'Frame'
mutable.listeners = t
mutable.threads = t
do
local t = t
listeners
{
get = function() return t end,
set = function(v) t = v end,
}
end
do
local t = t
threads
{
get = function() return t end,
set = function(v) t = v end,
}
end
do
local thread_id
+17 -2
View File
@@ -3,8 +3,23 @@ aux 'tooltip' local info, disenchant, cache, money, history = aux.info, aux.dise
_G.aux_tooltip_value = true
game_tooltip_hooks = t
mutable.hooked_setter = nil
mutable.game_tooltip_money = nil
do
local c
hooked_setter
{
get = function() return c end,
set = function(v) c = v end,
}
end
do
local amount
game_tooltip_money
{
get = function() return amount end,
set = function(v) amount = v end,
}
end
function LOAD()
for name, f in game_tooltip_hooks do
+25 -3
View File
@@ -32,9 +32,31 @@ end
existing_auctions = t
inventory_records = t
mutable.scan_id = 0
mutable.selected_item = nil
mutable.refresh = nil
do
local id = 0
scan_id
{
get = function() return id end,
set = function(v) id = v end,
}
end
do
local item
selected_item
{
get = function() return item end,
set = function(v) item = v end,
}
end
do
local c = 0
refresh
{
get = function() return c end,
set = function(v) c = v end,
}
end
function LOAD()
create_frames()
+16 -2
View File
@@ -2,8 +2,22 @@ aux 'search_tab' local info = aux.info
_G.aux_auto_buy_filter = ''
mutable.search_scan_id = 0
mutable.auto_buy_validator = nil
do
local id = 0
search_scan_id
{
get = function() return id end,
set = function(v) id = v end,
}
end
do
local validator
auto_buy_validator
{
get = function() return validator end,
set = function(v) validator = v end,
}
end
do
local searches = t