Mercurial > wow > askmrrobot
comparison ui/Ui.lua @ 61:cf2b6b9a8337 v23
6.2 update, shopping list bug fixes, ui scale option
| author | yellowfive |
|---|---|
| date | Tue, 23 Jun 2015 00:27:21 -0700 |
| parents | 01b63b8ed811 |
| children | 932885bb1a6f |
comparison
equal
deleted
inserted
replaced
| 60:017c05f42fd4 | 61:cf2b6b9a8337 |
|---|---|
| 147 f:SetLayout("None") | 147 f:SetLayout("None") |
| 148 f:SetWidth(1000) | 148 f:SetWidth(1000) |
| 149 f:SetHeight(700) | 149 f:SetHeight(700) |
| 150 f:SetBorderColor(Amr.Colors.BorderBlue) | 150 f:SetBorderColor(Amr.Colors.BorderBlue) |
| 151 f:SetBackgroundColor(Amr.Colors.Bg) | 151 f:SetBackgroundColor(Amr.Colors.Bg) |
| 152 | |
| 153 if Amr.db.profile.options.uiScale ~= 1 then | |
| 154 local scale = tonumber(Amr.db.profile.options.uiScale) | |
| 155 f:SetScale(scale) | |
| 156 end | |
| 152 | 157 |
| 153 -- some status text | 158 -- some status text |
| 154 local lblStatus = AceGUI:Create("AmrUiLabel") | 159 local lblStatus = AceGUI:Create("AmrUiLabel") |
| 155 lblStatus:SetWidth(900) | 160 lblStatus:SetWidth(900) |
| 156 lblStatus:SetFont(Amr.CreateFont("Italic", 12, Amr.Colors.TextTan)) | 161 lblStatus:SetFont(Amr.CreateFont("Italic", 12, Amr.Colors.TextTan)) |
| 336 | 341 |
| 337 -- show the active tab | 342 -- show the active tab |
| 338 _mainTabs:SelectTab(_activeTab) | 343 _mainTabs:SelectTab(_activeTab) |
| 339 end | 344 end |
| 340 | 345 |
| 346 function Amr:Reset() | |
| 347 if not self:IsEnabled() then return end | |
| 348 | |
| 349 Amr:Hide() | |
| 350 Amr:HideLootWindow() | |
| 351 Amr:HideShopWindow() | |
| 352 Amr.db.profile.options.uiScale = 1 | |
| 353 Amr.db.profile.window = {} | |
| 354 Amr.db.profile.lootWindow = {} | |
| 355 Amr.db.profile.shopWindow = {} | |
| 356 end | |
| 357 | |
| 341 -- show the UI if not shown already, and select the specified tab | 358 -- show the UI if not shown already, and select the specified tab |
| 342 function Amr:ShowTab(tab) | 359 function Amr:ShowTab(tab) |
| 343 if not self:IsEnabled() then return end | 360 if not self:IsEnabled() then return end |
| 344 | 361 |
| 345 _activeTab = tab | 362 _activeTab = tab |
