feat: localization
This commit is contained in:
+16
-16
@@ -156,7 +156,7 @@ function Guda_BagFrame_OnLoad(self)
|
||||
-- Set up search box placeholder
|
||||
local searchBox = getglobal(self:GetName().."_SearchBar_SearchBox")
|
||||
if searchBox then
|
||||
searchBox:SetText("Search, try ~equipment")
|
||||
searchBox:SetText(Guda_L["Search, try ~equipment"])
|
||||
searchBox:SetTextColor(0.5, 0.5, 0.5, 1)
|
||||
end
|
||||
|
||||
@@ -859,7 +859,7 @@ function BagFrame:Update()
|
||||
end
|
||||
|
||||
if titleFont and displayName then
|
||||
titleFont:SetText(string.format("%s's Bags", displayName))
|
||||
titleFont:SetText(string.format(Guda_L["%s's Bags"], displayName))
|
||||
end
|
||||
|
||||
-- Display items
|
||||
@@ -1604,7 +1604,7 @@ end
|
||||
|
||||
-- Check if search is currently active
|
||||
function BagFrame:IsSearchActive()
|
||||
return searchText and searchText ~= "" and searchText ~= "Search, try ~equipment"
|
||||
return searchText and searchText ~= "" and searchText ~= Guda_L["Search, try ~equipment"]
|
||||
end
|
||||
|
||||
-- Check if item passes search filter (pfUI style)
|
||||
@@ -1729,7 +1729,7 @@ function BagFrame:UpdateBagSlotsInfo(bagData, isOtherChar)
|
||||
infoFrame:EnableMouse(true)
|
||||
infoFrame:SetScript("OnEnter", function()
|
||||
GameTooltip:SetOwner(this, "ANCHOR_TOP")
|
||||
GameTooltip:AddLine("Bag Slots", 1, 1, 1)
|
||||
GameTooltip:AddLine(Guda_L["Bag Slots"], 1, 1, 1)
|
||||
GameTooltip:AddLine(" ")
|
||||
-- Regular bags
|
||||
if this.regularTotal then
|
||||
@@ -2209,7 +2209,7 @@ local function CreateMoneyTooltip()
|
||||
-- Header label
|
||||
f.header = f:CreateFontString(nil, "OVERLAY", "GameFontNormal")
|
||||
f.header:SetPoint("TOPLEFT", f, "TOPLEFT", 10, -10)
|
||||
f.header:SetText("Current realm gold")
|
||||
f.header:SetText(Guda_L["Current realm gold"])
|
||||
f.header:SetTextColor(1, 0.82, 0)
|
||||
|
||||
-- Header money frame (total) — anchored to right edge, same row as header
|
||||
@@ -2778,7 +2778,7 @@ end
|
||||
function Guda_BagFrame_ClearSearch()
|
||||
local searchBox = getglobal("Guda_BagFrame_SearchBar_SearchBox")
|
||||
if searchBox then
|
||||
searchBox:SetText("Search, try ~equipment")
|
||||
searchBox:SetText(Guda_L["Search, try ~equipment"])
|
||||
searchBox:SetTextColor(0.5, 0.5, 0.5, 1)
|
||||
searchBox:ClearFocus()
|
||||
end
|
||||
@@ -2797,7 +2797,7 @@ end
|
||||
function Guda_BagFrame_OnSearchChanged(self)
|
||||
local text = self:GetText()
|
||||
-- Ignore placeholder text
|
||||
if text == "Search, try ~equipment" then
|
||||
if text == Guda_L["Search, try ~equipment"] then
|
||||
text = ""
|
||||
end
|
||||
if text ~= searchText then
|
||||
@@ -2884,7 +2884,7 @@ end
|
||||
|
||||
function Guda_BagFrame_Sort()
|
||||
if currentViewChar then
|
||||
addon:Print("Cannot sort another character's bags!")
|
||||
addon:Print(Guda_L["Cannot sort another character's bags!"])
|
||||
return
|
||||
end
|
||||
|
||||
@@ -2903,7 +2903,7 @@ function Guda_BagFrame_Sort()
|
||||
)
|
||||
|
||||
if not success and message == "already sorted" then
|
||||
addon:Print("Bags are already sorted!")
|
||||
addon:Print(Guda_L["Bags are already sorted!"])
|
||||
end
|
||||
end
|
||||
|
||||
@@ -2917,7 +2917,7 @@ function Guda_BagFrame_MergeStacks()
|
||||
|
||||
-- Check if sorting is already in progress
|
||||
if addon.Modules.SortEngine.sortingInProgress then
|
||||
addon:Print("Sorting already in progress, please wait...")
|
||||
addon:Print(Guda_L["Sorting already in progress, please wait..."])
|
||||
return
|
||||
end
|
||||
|
||||
@@ -3042,7 +3042,7 @@ function Guda_BagFrame_MergeStacks()
|
||||
end
|
||||
-- Refresh the view
|
||||
BagFrame:Update()
|
||||
addon:Print("Restacked " .. totalMoves .. " stack(s)")
|
||||
addon:Print(format(Guda_L["Restacked %d stack(s)"], totalMoves))
|
||||
return
|
||||
end
|
||||
|
||||
@@ -3739,7 +3739,7 @@ function Guda_BagSlot_OnEnter(button, bagID)
|
||||
|
||||
if bagID == 0 then
|
||||
-- Backpack tooltip
|
||||
GameTooltip:SetText("Backpack", 1.0, 1.0, 1.0)
|
||||
GameTooltip:SetText(Guda_L["Backpack"], 1.0, 1.0, 1.0)
|
||||
local numSlots = GetContainerNumSlots(0)
|
||||
GameTooltip:AddLine(string.format("%d Slots", numSlots), 0.8, 0.8, 0.8)
|
||||
if hiddenBags[bagID] then
|
||||
@@ -3750,7 +3750,7 @@ function Guda_BagSlot_OnEnter(button, bagID)
|
||||
Guda_BagFrame_HighlightBagSlots(0)
|
||||
elseif bagID == -2 then
|
||||
-- Keyring tooltip
|
||||
GameTooltip:SetText("Keyring", 1.0, 1.0, 1.0)
|
||||
GameTooltip:SetText(Guda_L["Keyring"], 1.0, 1.0, 1.0)
|
||||
local numSlots = GetContainerNumSlots(-2) or 0
|
||||
GameTooltip:AddLine(string.format("%d Slots", numSlots), 0.8, 0.8, 0.8)
|
||||
if hiddenBags[bagID] then
|
||||
@@ -3775,7 +3775,7 @@ function Guda_BagSlot_OnEnter(button, bagID)
|
||||
Guda_BagFrame_HighlightBagSlots(bagID)
|
||||
else
|
||||
-- Empty slot
|
||||
GameTooltip:SetText(string.format("Bag %d", bagID), 1.0, 1.0, 1.0)
|
||||
GameTooltip:SetText(string.format(Guda_L["Bag %d"], bagID), 1.0, 1.0, 1.0)
|
||||
GameTooltip:AddLine("Empty", 0.5, 0.5, 0.5)
|
||||
if hiddenBags[bagID] then
|
||||
GameTooltip:AddLine("(Hidden - Right-Click to show)", 0.8, 0.5, 0.5)
|
||||
@@ -4134,7 +4134,7 @@ function BagFrame:Initialize()
|
||||
if not isMerchantOpen then
|
||||
this:SetScript("OnUpdate", nil)
|
||||
if soldCount > 0 then
|
||||
addon:Print("Sold " .. soldCount .. " junk item(s).")
|
||||
addon:Print(format(Guda_L["Sold %d junk item(s)"], soldCount))
|
||||
end
|
||||
return
|
||||
end
|
||||
@@ -4149,7 +4149,7 @@ function BagFrame:Initialize()
|
||||
else
|
||||
this:SetScript("OnUpdate", nil)
|
||||
if soldCount > 0 then
|
||||
addon:Print("Sold " .. soldCount .. " junk item(s).")
|
||||
addon:Print(format(Guda_L["Sold %d junk item(s)"], soldCount))
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
+17
-17
@@ -135,7 +135,7 @@ function Guda_BankFrame_OnLoad(self)
|
||||
-- Set up search box placeholder
|
||||
local searchBox = getglobal(self:GetName().."_SearchBar_SearchBox")
|
||||
if searchBox then
|
||||
searchBox:SetText("Search bank...")
|
||||
searchBox:SetText(Guda_L["Search bank..."])
|
||||
searchBox:SetTextColor(0.5, 0.5, 0.5, 1)
|
||||
end
|
||||
|
||||
@@ -641,7 +641,7 @@ function BankFrame:Update()
|
||||
bankData = addon.Modules.DB:GetCharacterBank(currentViewChar)
|
||||
isOtherChar = true
|
||||
charName = currentViewChar
|
||||
getglobal("Guda_BankFrame_Title"):SetText(currentViewChar .. "'s Bank")
|
||||
getglobal("Guda_BankFrame_Title"):SetText(format(Guda_L["%s's Bank"], currentViewChar))
|
||||
else
|
||||
-- Viewing current character's bank
|
||||
-- Use live data if bank is officially open OR if we can access bank data
|
||||
@@ -660,11 +660,11 @@ function BankFrame:Update()
|
||||
if useLiveData then
|
||||
-- Bank is accessible - use live data
|
||||
bankData = addon.Modules.BankScanner:GetBankData()
|
||||
getglobal("Guda_BankFrame_Title"):SetText(playerName .. "'s Bank")
|
||||
getglobal("Guda_BankFrame_Title"):SetText(format(Guda_L["%s's Bank"], playerName))
|
||||
else
|
||||
-- Bank is truly closed - use saved data (read-only mode)
|
||||
bankData = addon.Modules.DB:GetCharacterBank(playerName)
|
||||
getglobal("Guda_BankFrame_Title"):SetText(playerName .. "'s Bank")
|
||||
getglobal("Guda_BankFrame_Title"):SetText(format(Guda_L["%s's Bank"], playerName))
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1579,7 +1579,7 @@ end
|
||||
|
||||
-- Check if search is currently active
|
||||
function BankFrame:IsSearchActive()
|
||||
return searchText and searchText ~= "" and searchText ~= "Search bank..."
|
||||
return searchText and searchText ~= "" and searchText ~= Guda_L["Search bank..."]
|
||||
end
|
||||
|
||||
-- Check if item passes search filter (pfUI style)
|
||||
@@ -1592,7 +1592,7 @@ end
|
||||
function Guda_BankFrame_OnSearchChanged(self)
|
||||
local text = self:GetText()
|
||||
-- Ignore placeholder text
|
||||
if text == "Search bank..." then
|
||||
if text == Guda_L["Search bank..."] then
|
||||
text = ""
|
||||
end
|
||||
if text ~= searchText then
|
||||
@@ -1605,7 +1605,7 @@ end
|
||||
function Guda_BankFrame_ClearSearch()
|
||||
local searchBox = getglobal("Guda_BankFrame_SearchBar_SearchBox")
|
||||
if searchBox then
|
||||
searchBox:SetText("Search bank...")
|
||||
searchBox:SetText(Guda_L["Search bank..."])
|
||||
searchBox:SetTextColor(0.5, 0.5, 0.5, 1)
|
||||
if searchBox.ClearFocus then searchBox:ClearFocus() end
|
||||
end
|
||||
@@ -1625,12 +1625,12 @@ end
|
||||
-- Bank button handler
|
||||
function Guda_BankFrame_Sort()
|
||||
if isReadOnlyMode or currentViewChar then
|
||||
addon:Print("Cannot sort in read-only mode!")
|
||||
addon:Print(Guda_L["Cannot sort in read-only mode!"])
|
||||
return
|
||||
end
|
||||
|
||||
if not addon.Modules.BankScanner:IsBankOpen() then
|
||||
addon:Print("Bank must be open to sort!")
|
||||
addon:Print(Guda_L["Bank must be open to sort!"])
|
||||
return
|
||||
end
|
||||
|
||||
@@ -1649,7 +1649,7 @@ function Guda_BankFrame_Sort()
|
||||
)
|
||||
|
||||
if not success and message == "already sorted" then
|
||||
addon:Print("Bank is already sorted!")
|
||||
addon:Print(Guda_L["Bank is already sorted!"])
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1668,7 +1668,7 @@ function Guda_BankFrame_MergeStacks()
|
||||
|
||||
-- Check if sorting is already in progress
|
||||
if addon.Modules.SortEngine.sortingInProgress then
|
||||
addon:Print("Sorting already in progress, please wait...")
|
||||
addon:Print(Guda_L["Sorting already in progress, please wait..."])
|
||||
return
|
||||
end
|
||||
|
||||
@@ -1795,7 +1795,7 @@ function Guda_BankFrame_MergeStacks()
|
||||
addon.Modules.ItemDetection:ClearCache()
|
||||
end
|
||||
BankFrame:Update()
|
||||
addon:Print("Restacked " .. totalMoves .. " stack(s)")
|
||||
addon:Print(format(Guda_L["Restacked %d stack(s)"], totalMoves))
|
||||
return
|
||||
end
|
||||
|
||||
@@ -1884,7 +1884,7 @@ function Guda_BankFrame_SwitchToGudaUI()
|
||||
-- Update the custom bank frame in interactive mode
|
||||
BankFrame:ShowCurrentCharacter()
|
||||
|
||||
addon:Print("Switched to Guda bank UI")
|
||||
addon:Print(Guda_L["Switched to Guda bank UI"])
|
||||
end
|
||||
|
||||
-- Create button on Blizzard BankFrame to switch to Guda UI
|
||||
@@ -1927,7 +1927,7 @@ function BankFrame:CreateGudaButtonOnBlizzardUI()
|
||||
|
||||
gudaButton:SetScript("OnEnter", function()
|
||||
GameTooltip:SetOwner(this, "ANCHOR_LEFT")
|
||||
GameTooltip:SetText("Use Guda Bank UI")
|
||||
GameTooltip:SetText(Guda_L["Use Guda Bank UI"])
|
||||
GameTooltip:Show()
|
||||
end)
|
||||
|
||||
@@ -2658,7 +2658,7 @@ function Guda_BankBagSlot_OnEnter(button, bagID)
|
||||
|
||||
if bagID == -1 then
|
||||
-- Main bank bag tooltip
|
||||
GameTooltip:SetText("Bank", 1.0, 1.0, 1.0)
|
||||
GameTooltip:SetText(Guda_L["Bank"], 1.0, 1.0, 1.0)
|
||||
local numSlots = 24
|
||||
GameTooltip:AddLine(string.format("%d Slots", numSlots), 0.8, 0.8, 0.8)
|
||||
if hiddenBankBags[bagID] then
|
||||
@@ -2684,13 +2684,13 @@ function Guda_BankBagSlot_OnEnter(button, bagID)
|
||||
ResetCursor()
|
||||
elseif isPurchased then
|
||||
-- Empty purchased slot (no hide/show text, no purchase cursor)
|
||||
GameTooltip:SetText(string.format("Bank Bag Slot %d", bankButtonID or -1), 1.0, 1.0, 1.0)
|
||||
GameTooltip:SetText(string.format(Guda_L["Bank Bag Slot %d"], bankButtonID or -1), 1.0, 1.0, 1.0)
|
||||
GameTooltip:AddLine("Empty", 0.8, 0.8, 0.8)
|
||||
-- Reset cursor for empty purchased slots
|
||||
ResetCursor()
|
||||
else
|
||||
-- Unpurchased slot (no hide/show text, show purchase cursor)
|
||||
GameTooltip:SetText(string.format("Bank Bag Slot %d", bankButtonID or -1), 1.0, 1.0, 1.0)
|
||||
GameTooltip:SetText(string.format(Guda_L["Bank Bag Slot %d"], bankButtonID or -1), 1.0, 1.0, 1.0)
|
||||
local cost = GetBankSlotCost(numSlots)
|
||||
GameTooltip:AddLine(addon.Modules.Utils:FormatMoney(cost, false, true), 1, 1, 1)
|
||||
-- Show purchase cursor (coin icon)
|
||||
|
||||
+10
-10
@@ -695,13 +695,13 @@ UseContainerItem = function(bag, slot, ...)
|
||||
if itemID and DB:IsItemProtected(itemID) then
|
||||
-- Block selling at merchant
|
||||
if MerchantFrame and MerchantFrame:IsVisible() then
|
||||
addon:Print("Cannot sell " .. link .. " — item is protected")
|
||||
addon:Print(format(Guda_L["Cannot sell %s — item is protected"], link))
|
||||
return
|
||||
end
|
||||
-- Block disenchant/milling/prospecting (spell targeting an item)
|
||||
if SpellIsTargeting and SpellIsTargeting() then
|
||||
SpellStopTargeting()
|
||||
addon:Print("Cannot disenchant " .. link .. " — item is protected")
|
||||
addon:Print(format(Guda_L["Cannot disenchant %s — item is protected"], link))
|
||||
return
|
||||
end
|
||||
end
|
||||
@@ -739,7 +739,7 @@ local function HookDeletePopup(dialogName)
|
||||
local originalOnShow = StaticPopupDialogs[dialogName].OnShow
|
||||
StaticPopupDialogs[dialogName].OnShow = function()
|
||||
if cursorProtectedLink then
|
||||
addon:Print("Cannot delete " .. cursorProtectedLink .. " — item is protected")
|
||||
addon:Print(format(Guda_L["Cannot delete %s — item is protected"], cursorProtectedLink))
|
||||
ClearCursor()
|
||||
cursorProtectedLink = nil
|
||||
this:Hide()
|
||||
@@ -1092,9 +1092,9 @@ function Guda_ItemButton_OnLoad(self)
|
||||
if EquipSets and EquipSets.IsInSet and EquipSets:IsInSet(itemID) then
|
||||
local isNowExcepted = addon.Modules.DB:ToggleSetProtectionException(itemID)
|
||||
if isNowExcepted then
|
||||
addon:Print(link .. " set protection removed")
|
||||
addon:Print(format(Guda_L["%s set protection removed"], link))
|
||||
else
|
||||
addon:Print(link .. " set protection restored")
|
||||
addon:Print(format(Guda_L["%s set protection restored"], link))
|
||||
end
|
||||
-- Refresh bag/bank frames
|
||||
if addon.Modules.BagFrame and addon.Modules.BagFrame.Update then
|
||||
@@ -1108,9 +1108,9 @@ function Guda_ItemButton_OnLoad(self)
|
||||
end
|
||||
local isNowLocked = addon.Modules.DB:ToggleItemLock(itemID)
|
||||
if isNowLocked then
|
||||
addon:Print(link .. " locked")
|
||||
addon:Print(format(Guda_L["%s locked"], link))
|
||||
else
|
||||
addon:Print(link .. " unlocked")
|
||||
addon:Print(format(Guda_L["%s unlocked"], link))
|
||||
end
|
||||
-- Refresh bag/bank frames
|
||||
if addon.Modules.BagFrame and addon.Modules.BagFrame.Update then
|
||||
@@ -1133,9 +1133,9 @@ function Guda_ItemButton_OnLoad(self)
|
||||
itemName = " " .. this.itemData.link
|
||||
end
|
||||
if isNowPinned then
|
||||
addon:Print("Slot pinned" .. itemName .. " (skipped during sort)")
|
||||
addon:Print(format(Guda_L["Slot pinned %s (skipped during sort)"], itemName))
|
||||
else
|
||||
addon:Print("Slot unpinned" .. itemName)
|
||||
addon:Print(format(Guda_L["Slot unpinned %s"], itemName))
|
||||
end
|
||||
-- Refresh to show/hide pin icon
|
||||
if addon.Modules.BagFrame and addon.Modules.BagFrame.Update then
|
||||
@@ -1204,7 +1204,7 @@ function Guda_ItemButton_OnLoad(self)
|
||||
local itemID = addon.Modules.Utils:ExtractItemID(link)
|
||||
if itemID and addon.Modules.DB:IsItemProtected(itemID) then
|
||||
SpellStopTargeting()
|
||||
addon:Print("Cannot disenchant " .. link .. " — item is protected")
|
||||
addon:Print(format(Guda_L["Cannot disenchant %s — item is protected"], link))
|
||||
return
|
||||
end
|
||||
end
|
||||
|
||||
+5
-5
@@ -30,7 +30,7 @@ function Guda_MailboxFrame_OnLoad(self)
|
||||
-- Set up search box placeholder
|
||||
local searchBox = getglobal(self:GetName().."_SearchBar_SearchBox")
|
||||
if searchBox then
|
||||
searchBox:SetText("Search mailbox...")
|
||||
searchBox:SetText(Guda_L["Search mailbox..."])
|
||||
searchBox:SetTextColor(0.5, 0.5, 0.5, 1)
|
||||
end
|
||||
|
||||
@@ -148,7 +148,7 @@ function MailboxFrame:Update()
|
||||
charName = string.sub(charFullName, 1, dashPos - 1)
|
||||
end
|
||||
|
||||
getglobal("Guda_MailboxFrame_Title"):SetText(charName .. "'s Mailbox")
|
||||
getglobal("Guda_MailboxFrame_Title"):SetText(format(Guda_L["%s's Mailbox"], charName))
|
||||
|
||||
-- Filter items based on search text
|
||||
local filteredItems = {}
|
||||
@@ -175,7 +175,7 @@ function MailboxFrame:Update()
|
||||
local emptyMessage = getglobal("Guda_MailboxFrame_EmptyMessage")
|
||||
if emptyMessage then
|
||||
if totalItems == 0 then
|
||||
emptyMessage:SetText("No mailbox data found for this character.\n\nVisit a mailbox in-game to save your mail data.")
|
||||
emptyMessage:SetText(Guda_L["No mailbox data found for this character.\n\nVisit a mailbox in-game to save your mail data."])
|
||||
emptyMessage:Show()
|
||||
else
|
||||
emptyMessage:Hide()
|
||||
@@ -333,7 +333,7 @@ function MailboxFrame:DisplayItems(items, charFullName, totalMails)
|
||||
local paginationText = getglobal("Guda_MailboxFrame_Pagination_Text")
|
||||
if paginationText then
|
||||
if totalMails == 0 then
|
||||
paginationText:SetText("No Mail")
|
||||
paginationText:SetText(Guda_L["No Mail"])
|
||||
else
|
||||
paginationText:SetText(string.format("%d/%d (items: %d)", currentPage, totalPages, totalMails or 0))
|
||||
end
|
||||
@@ -344,7 +344,7 @@ end
|
||||
function Guda_MailboxFrame_OnSearchTextChanged()
|
||||
local searchBox = getglobal("Guda_MailboxFrame_SearchBar_SearchBox")
|
||||
local text = searchBox:GetText()
|
||||
if text == "Search mailbox..." then
|
||||
if text == Guda_L["Search mailbox..."] then
|
||||
searchText = ""
|
||||
else
|
||||
searchText = string.lower(text)
|
||||
|
||||
+2
-2
@@ -272,7 +272,7 @@ function QuestItemBar:Update()
|
||||
|
||||
button:SetScript("OnClick", function()
|
||||
if this.fromDB then
|
||||
addon:Print("Item is not currently in your bags (loading from database).")
|
||||
addon:Print(Guda_L["Item is not currently in your bags (loading from database)."])
|
||||
return
|
||||
end
|
||||
|
||||
@@ -613,7 +613,7 @@ function QuestItemBar:UpdateFlyout(parent)
|
||||
|
||||
btn:SetScript("OnClick", function()
|
||||
if this.fromDB then
|
||||
addon:Print("Item is not currently in your bags (loading from database).")
|
||||
addon:Print(Guda_L["Item is not currently in your bags (loading from database)."])
|
||||
return
|
||||
end
|
||||
|
||||
|
||||
+47
-47
@@ -39,7 +39,7 @@ function Guda_SettingsPopup_OnLoad(self)
|
||||
Guda:ApplyBackdrop(self, "DEFAULT_FRAME")
|
||||
|
||||
local title = getglobal(self:GetName().."_Title")
|
||||
title:SetText("Guda Settings")
|
||||
title:SetText(Guda_L["Guda Settings"])
|
||||
-- Increase title font size
|
||||
local titleFont, _, titleFlags = title:GetFont()
|
||||
if titleFont then
|
||||
@@ -405,7 +405,7 @@ function Guda_SettingsPopup_BagColumnsSlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("20")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Bag columns")
|
||||
text:SetText(Guda_L["Bag columns"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -443,7 +443,7 @@ function Guda_SettingsPopup_BankColumnsSlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("20")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Bank columns")
|
||||
text:SetText(Guda_L["Bank columns"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -481,7 +481,7 @@ function Guda_SettingsPopup_BgTransparencySlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("100%")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Background Transparency")
|
||||
text:SetText(Guda_L["Background Transparency"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -540,7 +540,7 @@ function Guda_SettingsPopup_IconSizeSlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("64px")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Icon size")
|
||||
text:SetText(Guda_L["Icon size"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -580,7 +580,7 @@ function Guda_SettingsPopup_IconFontSizeSlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("20px")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Icon font size")
|
||||
text:SetText(Guda_L["Icon font size"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -620,7 +620,7 @@ function Guda_SettingsPopup_IconSpacingSlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("20px")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Icon spacing")
|
||||
text:SetText(Guda_L["Icon spacing"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -666,7 +666,7 @@ function Guda_SettingsPopup_QuestBarSizeSlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("64px")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Quest bar size")
|
||||
text:SetText(Guda_L["Quest bar size"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -701,7 +701,7 @@ function Guda_SettingsPopup_TrackedBarSizeSlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("64px")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Tracked bar size")
|
||||
text:SetText(Guda_L["Tracked bar size"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -734,7 +734,7 @@ end
|
||||
function Guda_SettingsPopup_LockBagsCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Lock Window")
|
||||
text:SetText(Guda_L["Lock Window"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -781,7 +781,7 @@ end
|
||||
function Guda_SettingsPopup_HideBordersCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Hide Frame Borders")
|
||||
text:SetText(Guda_L["Hide Frame Borders"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -840,7 +840,7 @@ end
|
||||
function Guda_SettingsPopup_QualityBorderEquipmentCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Equipment Borders")
|
||||
text:SetText(Guda_L["Equipment Borders"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -888,7 +888,7 @@ end
|
||||
function Guda_SettingsPopup_QualityBorderOtherCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Other Item Borders")
|
||||
text:SetText(Guda_L["Other Item Borders"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -936,7 +936,7 @@ end
|
||||
function Guda_SettingsPopup_ShowSearchBarCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Show Search Bar")
|
||||
text:SetText(Guda_L["Show Search Bar"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -993,7 +993,7 @@ end
|
||||
function Guda_SettingsPopup_ShowQuestBarCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Show Quest Bar")
|
||||
text:SetText(Guda_L["Show Quest Bar"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -1035,7 +1035,7 @@ end
|
||||
function Guda_SettingsPopup_HoverBaglineCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Show All Bags")
|
||||
text:SetText(Guda_L["Show All Bags"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -1087,7 +1087,7 @@ end
|
||||
function Guda_SettingsPopup_HideFooterCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Hide Footer")
|
||||
text:SetText(Guda_L["Hide Footer"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -1181,7 +1181,7 @@ function Guda_SettingsPopup_JunkOpacitySlider_OnLoad(self)
|
||||
getglobal(self:GetName().."High"):SetText("100%")
|
||||
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
text:SetText("Junk item opacity")
|
||||
text:SetText(Guda_L["Junk item opacity"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -1225,7 +1225,7 @@ end
|
||||
function Guda_SettingsPopup_MarkUnusableCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Mark Unusable Items")
|
||||
text:SetText(Guda_L["Mark Unusable Items"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -1273,7 +1273,7 @@ end
|
||||
function Guda_SettingsPopup_ShowEquipSetCategoriesCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Equip Set Categories")
|
||||
text:SetText(Guda_L["Equip Set Categories"])
|
||||
|
||||
local font, _, flags = text:GetFont()
|
||||
if font then
|
||||
@@ -1315,7 +1315,7 @@ end
|
||||
function Guda_SettingsPopup_MarkEquipmentSetsCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Mark Equipment Sets")
|
||||
text:SetText(Guda_L["Mark Equipment Sets"])
|
||||
|
||||
local font, _, flags = text:GetFont()
|
||||
if font then
|
||||
@@ -1357,7 +1357,7 @@ end
|
||||
function Guda_SettingsPopup_AutoLockSetItemsCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Auto Lock Set Items")
|
||||
text:SetText(Guda_L["Auto Lock Set Items"])
|
||||
|
||||
local font, _, flags = text:GetFont()
|
||||
if font then
|
||||
@@ -1389,7 +1389,7 @@ end
|
||||
function Guda_SettingsPopup_ShowCategoryCountCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Show Category Count")
|
||||
text:SetText(Guda_L["Show Category Count"])
|
||||
|
||||
local font, _, flags = text:GetFont()
|
||||
if font then
|
||||
@@ -1431,7 +1431,7 @@ end
|
||||
function Guda_SettingsPopup_AutoVendorJunkCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Auto Sell Junk")
|
||||
text:SetText(Guda_L["Auto Sell Junk"])
|
||||
|
||||
local font, _, flags = text:GetFont()
|
||||
if font then
|
||||
@@ -1463,7 +1463,7 @@ end
|
||||
function Guda_SettingsPopup_AutoOpenBagsCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Auto Open Bags")
|
||||
text:SetText(Guda_L["Auto Open Bags"])
|
||||
|
||||
local font, _, flags = text:GetFont()
|
||||
if font then
|
||||
@@ -1495,7 +1495,7 @@ end
|
||||
function Guda_SettingsPopup_AutoCloseBagsCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Auto Close Bags")
|
||||
text:SetText(Guda_L["Auto Close Bags"])
|
||||
|
||||
local font, _, flags = text:GetFont()
|
||||
if font then
|
||||
@@ -1527,7 +1527,7 @@ end
|
||||
function Guda_SettingsPopup_WhiteItemsJunkCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("White Items as Junk")
|
||||
text:SetText(Guda_L["White Items as Junk"])
|
||||
|
||||
local font, _, flags = text:GetFont()
|
||||
if font then
|
||||
@@ -1643,7 +1643,7 @@ function Guda_SettingsPopup_ThemeDropdown_OnLoad(self)
|
||||
-- Add label above dropdown
|
||||
local label = self:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
|
||||
label:SetPoint("BOTTOMLEFT", self, "TOPLEFT", 20, 2)
|
||||
label:SetText("Theme")
|
||||
label:SetText(Guda_L["Theme"])
|
||||
label:SetTextColor(1, 0.82, 0, 1)
|
||||
end
|
||||
|
||||
@@ -1761,7 +1761,7 @@ function Guda_SettingsPopup_BagViewDropdown_OnLoad(self)
|
||||
|
||||
local label = self:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
|
||||
label:SetPoint("BOTTOMLEFT", self, "TOPLEFT", 20, 2)
|
||||
label:SetText("Bag View")
|
||||
label:SetText(Guda_L["Bag View"])
|
||||
label:SetTextColor(1, 0.82, 0, 1)
|
||||
end
|
||||
|
||||
@@ -1800,7 +1800,7 @@ function Guda_SettingsPopup_BankViewDropdown_OnLoad(self)
|
||||
|
||||
local label = self:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
|
||||
label:SetPoint("BOTTOMLEFT", self, "TOPLEFT", 20, 2)
|
||||
label:SetText("Bank View")
|
||||
label:SetText(Guda_L["Bank View"])
|
||||
label:SetTextColor(1, 0.82, 0, 1)
|
||||
end
|
||||
|
||||
@@ -1808,7 +1808,7 @@ end
|
||||
function Guda_SettingsPopup_ReverseStackSortCheckbox_OnLoad(self)
|
||||
local text = getglobal(self:GetName().."Text")
|
||||
if text then
|
||||
text:SetText("Reverse Stack Sort")
|
||||
text:SetText(Guda_L["Reverse Stack Sort"])
|
||||
|
||||
-- Increase font size
|
||||
local font, _, flags = text:GetFont()
|
||||
@@ -1901,7 +1901,7 @@ local function GetCategoryRowFrame(index)
|
||||
editBtn:SetWidth(40)
|
||||
editBtn:SetHeight(18)
|
||||
editBtn:SetPoint("LEFT", nameText, "RIGHT", 5, 0)
|
||||
editBtn:SetText("Edit")
|
||||
editBtn:SetText(Guda_L["Edit"])
|
||||
editBtn:SetScript("OnClick", function()
|
||||
local catId = this:GetParent().categoryId
|
||||
if catId then
|
||||
@@ -1991,7 +1991,7 @@ local function GetCategoryRowFrame(index)
|
||||
end)
|
||||
local mergeLabel = row:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
|
||||
mergeLabel:SetPoint("RIGHT", mergeCheckbox, "LEFT", -2, 0)
|
||||
mergeLabel:SetText("Merge")
|
||||
mergeLabel:SetText(Guda_L["Merge"])
|
||||
mergeLabel:SetTextColor(0.8, 0.8, 0.8)
|
||||
row.mergeCheckbox = mergeCheckbox
|
||||
row.mergeLabel = mergeLabel
|
||||
@@ -2141,12 +2141,12 @@ function Guda_SettingsPopup_CategoriesTab_Update()
|
||||
-- Set button texts
|
||||
local addBtn = getglobal("Guda_SettingsPopup_AddCategoryButton")
|
||||
if addBtn then
|
||||
addBtn:SetText("+ Add Category")
|
||||
addBtn:SetText(Guda_L["+ Add Category"])
|
||||
end
|
||||
|
||||
local resetBtn = getglobal("Guda_SettingsPopup_ResetCategoriesButton")
|
||||
if resetBtn then
|
||||
resetBtn:SetText("Reset Defaults")
|
||||
resetBtn:SetText(Guda_L["Reset Defaults"])
|
||||
end
|
||||
end
|
||||
|
||||
@@ -2262,13 +2262,13 @@ function Guda_CategoryEditor_OnLoad(self)
|
||||
|
||||
-- Set button texts
|
||||
local addBtn = getglobal("Guda_CategoryEditor_AddRuleButton")
|
||||
if addBtn then addBtn:SetText("+ Add Rule") end
|
||||
if addBtn then addBtn:SetText(Guda_L["+ Add Rule"]) end
|
||||
|
||||
local saveBtn = getglobal("Guda_CategoryEditor_SaveButton")
|
||||
if saveBtn then saveBtn:SetText("Save") end
|
||||
if saveBtn then saveBtn:SetText(Guda_L["Save"]) end
|
||||
|
||||
local cancelBtn = getglobal("Guda_CategoryEditor_CancelButton")
|
||||
if cancelBtn then cancelBtn:SetText("Cancel") end
|
||||
if cancelBtn then cancelBtn:SetText(Guda_L["Cancel"]) end
|
||||
|
||||
-- Create group EditBox if it doesn't exist
|
||||
if not getglobal("Guda_CategoryEditor_GroupEditBox") then
|
||||
@@ -2277,7 +2277,7 @@ function Guda_CategoryEditor_OnLoad(self)
|
||||
-- Label
|
||||
local groupLabel = self:CreateFontString("Guda_CategoryEditor_GroupLabel", "OVERLAY", "GameFontNormalSmall")
|
||||
groupLabel:SetPoint("LEFT", nameBox, "RIGHT", 14, 0)
|
||||
groupLabel:SetText("Group:")
|
||||
groupLabel:SetText(Guda_L["Group:"])
|
||||
groupLabel:SetTextColor(0.7, 0.7, 0.7)
|
||||
|
||||
-- EditBox
|
||||
@@ -2299,7 +2299,7 @@ function Guda_CategoryEditor_OnLoad(self)
|
||||
|
||||
local markLabel = self:CreateFontString("Guda_CategoryEditor_MarkLabel", "OVERLAY", "GameFontNormalSmall")
|
||||
markLabel:SetPoint("TOPLEFT", self, "TOPLEFT", 20, -78)
|
||||
markLabel:SetText("Mark:")
|
||||
markLabel:SetText(Guda_L["Mark:"])
|
||||
markLabel:SetTextColor(0.7, 0.7, 0.7)
|
||||
|
||||
-- "None" button (first)
|
||||
@@ -2360,14 +2360,14 @@ function Guda_CategoryEditor_OnLoad(self)
|
||||
if anyRadio then
|
||||
local label = anyRadio:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
|
||||
label:SetPoint("LEFT", anyRadio, "RIGHT", 2, 0)
|
||||
label:SetText("Any rule")
|
||||
label:SetText(Guda_L["Any rule"])
|
||||
end
|
||||
|
||||
local allRadio = getglobal("Guda_CategoryEditor_MatchAll")
|
||||
if allRadio then
|
||||
local label = allRadio:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
|
||||
label:SetPoint("LEFT", allRadio, "RIGHT", 2, 0)
|
||||
label:SetText("All rules")
|
||||
label:SetText(Guda_L["All rules"])
|
||||
end
|
||||
end
|
||||
|
||||
@@ -2413,9 +2413,9 @@ function Guda_CategoryEditor_Open(categoryId)
|
||||
local title = getglobal("Guda_CategoryEditor_Title")
|
||||
if title then
|
||||
if categoryDef.isBuiltIn then
|
||||
title:SetText("Edit Category (Built-in)")
|
||||
title:SetText(Guda_L["Edit Category (Built-in)"])
|
||||
else
|
||||
title:SetText("Edit Category")
|
||||
title:SetText(Guda_L["Edit Category"])
|
||||
end
|
||||
end
|
||||
|
||||
@@ -2498,7 +2498,7 @@ local function GetRuleRowFrame(index)
|
||||
typeBtn:SetWidth(120)
|
||||
typeBtn:SetHeight(22)
|
||||
typeBtn:SetPoint("LEFT", row, "LEFT", 0, 0)
|
||||
typeBtn:SetText("Select Type")
|
||||
typeBtn:SetText(Guda_L["Select Type"])
|
||||
typeBtn.ruleIndex = index
|
||||
typeBtn:SetScript("OnClick", function()
|
||||
Guda_CategoryEditor_ShowTypeDropdown(this, this.ruleIndex)
|
||||
@@ -2527,7 +2527,7 @@ local function GetRuleRowFrame(index)
|
||||
valueBtn:SetWidth(140)
|
||||
valueBtn:SetHeight(22)
|
||||
valueBtn:SetPoint("LEFT", typeBtn, "RIGHT", 5, 0)
|
||||
valueBtn:SetText("Select Value")
|
||||
valueBtn:SetText(Guda_L["Select Value"])
|
||||
valueBtn.ruleIndex = index
|
||||
valueBtn:SetScript("OnClick", function()
|
||||
Guda_CategoryEditor_ShowValueDropdown(this, this.ruleIndex)
|
||||
@@ -2672,7 +2672,7 @@ function Guda_CategoryEditor_UpdateRulesDisplay()
|
||||
-- Update rules count label
|
||||
local rulesLabel = getglobal("Guda_CategoryEditor_RulesLabel")
|
||||
if rulesLabel then
|
||||
rulesLabel:SetText("Rules (" .. numRules .. "/" .. MAX_RULES .. "):")
|
||||
rulesLabel:SetText(format(Guda_L["Rules (%d/%d):"], numRules, MAX_RULES))
|
||||
end
|
||||
|
||||
-- Update scroll frame
|
||||
|
||||
Reference in New Issue
Block a user