automatically clearing filter
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
Aux = {
|
Aux = {
|
||||||
version = '2.6.7',
|
version = '2.6.8',
|
||||||
blizzard_ui_shown = false,
|
blizzard_ui_shown = false,
|
||||||
orig = {},
|
orig = {},
|
||||||
}
|
}
|
||||||
|
|||||||
+7
-10
@@ -106,7 +106,7 @@ function private.add_filter(filter_string, replace)
|
|||||||
private.search_box:SetText((old_filter_string or '')..filter_string)
|
private.search_box:SetText((old_filter_string or '')..filter_string)
|
||||||
end
|
end
|
||||||
|
|
||||||
function private.clear_filter()
|
function private.clear_form()
|
||||||
AuxSearchFrameFilterNameInputBox:SetText('')
|
AuxSearchFrameFilterNameInputBox:SetText('')
|
||||||
AuxSearchFrameFilterExactCheckButton:SetChecked(nil)
|
AuxSearchFrameFilterExactCheckButton:SetChecked(nil)
|
||||||
AuxSearchFrameFilterMinLevel:SetText('')
|
AuxSearchFrameFilterMinLevel:SetText('')
|
||||||
@@ -116,14 +116,6 @@ function private.clear_filter()
|
|||||||
UIDropDownMenu_ClearAll(private.slot_dropdown)
|
UIDropDownMenu_ClearAll(private.slot_dropdown)
|
||||||
UIDropDownMenu_ClearAll(private.quality_dropdown)
|
UIDropDownMenu_ClearAll(private.quality_dropdown)
|
||||||
AuxSearchFrameFilterUsableCheckButton:SetChecked(nil)
|
AuxSearchFrameFilterUsableCheckButton:SetChecked(nil)
|
||||||
private.max_buyout_price:SetText('')
|
|
||||||
private.max_percent:SetText('')
|
|
||||||
private.tooltip1:SetText('')
|
|
||||||
private.tooltip2:SetText('')
|
|
||||||
private.tooltip3:SetText('')
|
|
||||||
private.tooltip4:SetText('')
|
|
||||||
private.tooltip5:SetText('')
|
|
||||||
private.tooltip6:SetText('')
|
|
||||||
end
|
end
|
||||||
|
|
||||||
function private.get_form_filter()
|
function private.get_form_filter()
|
||||||
@@ -306,6 +298,7 @@ function public.on_load()
|
|||||||
btn1:SetScript('OnClick', function()
|
btn1:SetScript('OnClick', function()
|
||||||
private.search_box:SetText('')
|
private.search_box:SetText('')
|
||||||
private.add_filter()
|
private.add_filter()
|
||||||
|
private.clear_form()
|
||||||
public.start_search()
|
public.start_search()
|
||||||
end)
|
end)
|
||||||
|
|
||||||
@@ -314,7 +307,10 @@ function public.on_load()
|
|||||||
btn2:SetWidth(80)
|
btn2:SetWidth(80)
|
||||||
btn2:SetHeight(24)
|
btn2:SetHeight(24)
|
||||||
btn2:SetText('Add')
|
btn2:SetText('Add')
|
||||||
btn2:SetScript('OnClick', private.add_filter)
|
btn2:SetScript('OnClick', function()
|
||||||
|
private.add_filter()
|
||||||
|
private.clear_form()
|
||||||
|
end)
|
||||||
|
|
||||||
local btn3 = Aux.gui.button(AuxSearchFrameFilter, 16)
|
local btn3 = Aux.gui.button(AuxSearchFrameFilter, 16)
|
||||||
btn3:SetPoint('LEFT', btn2, 'RIGHT', 5, 0)
|
btn3:SetPoint('LEFT', btn2, 'RIGHT', 5, 0)
|
||||||
@@ -323,6 +319,7 @@ function public.on_load()
|
|||||||
btn3:SetText('Replace')
|
btn3:SetText('Replace')
|
||||||
btn3:SetScript('OnClick', function()
|
btn3:SetScript('OnClick', function()
|
||||||
private.add_filter(nil, true)
|
private.add_filter(nil, true)
|
||||||
|
private.clear_form()
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
do
|
do
|
||||||
|
|||||||
Reference in New Issue
Block a user