Mercurial > wow > askmrrobot
comparison config.lua @ 17:e77e01abce98
Warlords of Draenor pre-patch
| author | Adam tegen <adam.tegen@gmail.com> |
|---|---|
| date | Mon, 13 Oct 2014 21:28:32 -0500 |
| parents | ece9167c0d1c |
| children | 6f1bb8fcf64d |
comparison
equal
deleted
inserted
replaced
| 16:9793e8b683d2 | 17:e77e01abce98 |
|---|---|
| 1 local addonName, AskMrRobot = ... | 1 local addonName, AskMrRobot = ... |
| 2 | |
| 3 --if not addon.healthCheck then return end | |
| 4 local L = AskMrRobot.L | 2 local L = AskMrRobot.L |
| 5 | 3 |
| 6 local wow_ver = select(4, GetBuildInfo()) | 4 local wow_ver = select(4, GetBuildInfo()) |
| 7 local wow_500 = wow_ver >= 50000 | 5 local wow_500 = wow_ver >= 50000 |
| 8 local UIPanelButtonTemplate = wow_500 and "UIPanelButtonTemplate" or "UIPanelButtonTemplate2" | 6 local UIPanelButtonTemplate = wow_500 and "UIPanelButtonTemplate" or "UIPanelButtonTemplate2" |
| 41 subtitle:SetNonSpaceWrap(false) | 39 subtitle:SetNonSpaceWrap(false) |
| 42 subtitle:SetJustifyV("TOP") | 40 subtitle:SetJustifyV("TOP") |
| 43 subtitle:SetText(L.AMR_CONFIG_EXIMPORT) | 41 subtitle:SetText(L.AMR_CONFIG_EXIMPORT) |
| 44 subTitleWrapper:SetHeight(subtitle:GetHeight()) | 42 subTitleWrapper:SetHeight(subtitle:GetHeight()) |
| 45 | 43 |
| 44 -- hide minimap icon | |
| 46 local autoPopup = newCheckbox( | 45 local autoPopup = newCheckbox( |
| 47 L.AMR_CONFIG_CHECKBOX_MINIMAP_LABEL, | 46 L.AMR_CONFIG_CHECKBOX_MINIMAP_LABEL, |
| 48 L.AMR_CONFIG_CHECKBOX_MINIMAP_TOOLTIP_TITLE, | 47 L.AMR_CONFIG_CHECKBOX_MINIMAP_TOOLTIP_TITLE, |
| 49 L.AMR_CONFIG_CHECKBOX_MINIMAP_DESCRIPTION, | 48 L.AMR_CONFIG_CHECKBOX_MINIMAP_DESCRIPTION, |
| 50 function(self, value) | 49 function(self, value) |
| 51 if AmrOptions.hideMapIcon then | 50 if AmrDb.Options.hideMapIcon then |
| 52 AmrOptions.hideMapIcon = false | 51 AmrDb.Options.hideMapIcon = false |
| 53 else | 52 else |
| 54 AmrOptions.hideMapIcon = true | 53 AmrDb.Options.hideMapIcon = true |
| 55 end | 54 end |
| 56 AskMrRobot.AmrUpdateMinimap(); | 55 AskMrRobot.AmrUpdateMinimap(); |
| 57 end | 56 end |
| 58 ) | 57 ) |
| 59 autoPopup:SetChecked(not AmrOptions.hideMapIcon) | 58 autoPopup:SetChecked(not AmrDb.Options.hideMapIcon) |
| 60 autoPopup:SetPoint("TOPLEFT", subTitleWrapper, "BOTTOMLEFT", -2, -16) | 59 autoPopup:SetPoint("TOPLEFT", subTitleWrapper, "BOTTOMLEFT", -2, -16) |
| 61 | 60 |
| 62 local autoReforge = newCheckbox( | |
| 63 L.AMR_CONFIG_CHECKBOX_AUTOREFORGE_LABEL, | |
| 64 L.AMR_CONFIG_CHECKBOX_AUTOREFORGE_TOOLTIP_TITLE, | |
| 65 L.AMR_CONFIG_CHECKBOX_AUTOREFORGE_DESCRIPTION, | |
| 66 function(self, value) | |
| 67 if AmrOptions.manualShowReforge then | |
| 68 AmrOptions.manualShowReforge = false | |
| 69 else | |
| 70 AmrOptions.manualShowReforge = true | |
| 71 end | |
| 72 end | |
| 73 ) | |
| 74 autoReforge:SetChecked(not AmrOptions.manualShowReforge) | |
| 75 autoReforge:SetPoint("TOPLEFT", subTitleWrapper, "BOTTOMLEFT", -2, -52) | |
| 76 | 61 |
| 62 -- auto-show at auction house | |
| 77 local autoAh = newCheckbox( | 63 local autoAh = newCheckbox( |
| 78 L.AMR_CONFIG_CHECKBOX_AUTOAH_LABEL, | 64 L.AMR_CONFIG_CHECKBOX_AUTOAH_LABEL, |
| 79 L.AMR_CONFIG_CHECKBOX_AUTOAH_TOOLTIP_TITLE, | 65 L.AMR_CONFIG_CHECKBOX_AUTOAH_TOOLTIP_TITLE, |
| 80 L.AMR_CONFIG_CHECKBOX_AUTOAH_DESCRIPTION, | 66 L.AMR_CONFIG_CHECKBOX_AUTOAH_DESCRIPTION, |
| 81 function(self, value) | 67 function(self, value) |
| 82 if AmrOptions.manualShowShop then | 68 if AmrDb.Options.manualShowShop then |
| 83 AmrOptions.manualShowShop = false | 69 AmrDb.Options.manualShowShop = false |
| 84 else | 70 else |
| 85 AmrOptions.manualShowShop = true | 71 AmrDb.Options.manualShowShop = true |
| 86 end | 72 end |
| 87 end | 73 end |
| 88 ) | 74 ) |
| 89 autoAh:SetChecked(not AmrOptions.manualShowShop) | 75 autoAh:SetChecked(not AmrDb.Options.manualShowShop) |
| 90 autoAh:SetPoint("TOPLEFT", subTitleWrapper, "BOTTOMLEFT", -2, -88) | 76 autoAh:SetPoint("TOPLEFT", subTitleWrapper, "BOTTOMLEFT", -2, -58) |
| 91 | |
| 92 --[[ | |
| 93 AmrOptions.autoLog = AmrOptions.autoLog or {} | |
| 94 | |
| 95 local autoCombatLog = newCheckbox( | |
| 96 L.AMR_CONFIG_CHECKBOX_AUTOLOG_LABEL, | |
| 97 L.AMR_CONFIG_CHECKBOX_AUTOLOG_TOOLTIP_TITLE, | |
| 98 L.AMR_CONFIG_CHECKBOX_AUTOLOG_DESCRIPTION, | |
| 99 function(self, value) | |
| 100 if AmrOptions.autoLog[1136] then | |
| 101 AmrOptions.autoLog[1136] = false | |
| 102 else | |
| 103 AmrOptions.autoLog[1136] = true | |
| 104 end | |
| 105 end | |
| 106 ) | |
| 107 autoCombatLog:SetChecked(AmrOptions.autoLog[1136]) | |
| 108 autoCombatLog:SetPoint("TOPLEFT", subTitleWrapper, "BOTTOMLEFT", -2, -124) | |
| 109 ]] | |
| 110 | 77 |
| 111 frame:SetScript("OnShow", nil) | 78 frame:SetScript("OnShow", nil) |
| 112 end) | 79 end) |
| 113 InterfaceOptions_AddCategory(frame) | 80 InterfaceOptions_AddCategory(frame) |
| 114 | 81 |
