filter arity input inprovement

This commit is contained in:
Manuel Simon Hirsig
2016-08-02 08:41:58 +02:00
parent 7b3aedd206
commit c1e79c63d8
3 changed files with 42 additions and 45 deletions
+5 -16
View File
@@ -386,10 +386,7 @@ Aux.search_tab.FRAMES(function(m, public, private)
m.min_level_input:SetFocus()
end
end)
editbox:SetScript('OnEnterPressed', function()
this:ClearFocus()
m.execute()
end)
editbox:SetScript('OnEnterPressed', Aux.f(editbox.ClearFocus, editbox))
local label = Aux.gui.label(editbox, 13)
label:SetPoint('BOTTOMLEFT', editbox, 'TOPLEFT', -2, 1)
label:SetText('Name')
@@ -418,10 +415,7 @@ Aux.search_tab.FRAMES(function(m, public, private)
m.max_level_input:SetFocus()
end
end)
editbox:SetScript('OnEnterPressed', function()
this:ClearFocus()
m.execute()
end)
editbox:SetScript('OnEnterPressed', Aux.f(editbox.ClearFocus, editbox))
local label = Aux.gui.label(editbox, 13)
label:SetPoint('BOTTOMLEFT', editbox, 'TOPLEFT', -2, 1)
label:SetText('Level Range')
@@ -440,10 +434,7 @@ Aux.search_tab.FRAMES(function(m, public, private)
m.name_input:SetFocus()
end
end)
editbox:SetScript('OnEnterPressed', function()
this:ClearFocus()
m.execute()
end)
editbox:SetScript('OnEnterPressed', Aux.f(editbox.ClearFocus, editbox))
local label = Aux.gui.label(editbox, 13)
label:SetPoint('RIGHT', editbox, 'LEFT', -3.5, 0)
label:SetText('-')
@@ -539,7 +530,7 @@ Aux.search_tab.FRAMES(function(m, public, private)
btn:RegisterForClicks('LeftButtonUp', 'RightButtonUp')
btn:SetScript('OnClick', function()
if arg1 == 'LeftButton' then
m.add_post_filter()
m.add_post_component()
elseif arg1 == 'RightButton' then
m.remove_post_filter()
end
@@ -551,12 +542,10 @@ Aux.search_tab.FRAMES(function(m, public, private)
input:SetPoint('LEFT', m.filter_dropdown, 'RIGHT', 10, 0)
input:SetWidth(150)
input:SetHeight(25)
-- editbox:SetNumeric(true)
-- editbox:SetMaxLetters(2)
input:SetScript('OnChar', function()
this:complete()
end)
input:SetScript('OnEnterPressed', m.add_post_filter)
input:SetScript('OnEnterPressed', m.add_post_component)
input:Hide()
private.filter_input = input
end