diff --git a/CommunityDKP.lua b/CommunityDKP.lua index a9bc0b37..3a9a8e8a 100644 --- a/CommunityDKP.lua +++ b/CommunityDKP.lua @@ -372,7 +372,8 @@ function CommDKP:CreateMenu() SortButtons.class.t:SetText(L["CLASS"]); --]] -- center column dropdown (class, rank, spec etc..) - SortButtons.class.t = CreateFrame("FRAME", "CommDKPSortColDropdown", SortButtons.class, "CommunityDKPTableHeaderDropDownMenuTemplate") + --SortButtons.class.t = CreateFrame("FRAME", "CommDKPSortColDropdown", SortButtons.class, "CommunityDKPTableHeaderDropDownMenuTemplate") + SortButtons.class.t = LibDD:Create_UIDropDownMenu("CommDKPSortColDropdown", SortButtons.class) SortButtons.class.t:SetPoint("CENTER", SortButtons.class, "CENTER", 4, -3) LibDD:UIDropDownMenu_JustifyText(SortButtons.class.t, "CENTER") LibDD:UIDropDownMenu_SetWidth(SortButtons.class.t, 80) @@ -400,7 +401,7 @@ function CommDKP:CreateMenu() LibDD:UIDropDownMenu_SetText(SortButtons.class.t, arg2) CommDKP:SortDKPTable(newValue, "reset") core.currentSort = newValue; - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end SortButtons.dkp.t = SortButtons.dkp:CreateFontString(nil, "OVERLAY") SortButtons.dkp.t:SetFontObject("CommDKPNormal") @@ -506,7 +507,8 @@ function CommDKP:CreateMenu() -- Team view changer Drop Down ------------------------------ - CommDKP.UIConfig.TeamViewChangerDropDown = CreateFrame("FRAME", "CommDKPConfigReasonDropDown", CommDKP.UIConfig, "CommunityDKPUIDropDownMenuTemplate") + --CommDKP.UIConfig.TeamViewChangerDropDown = CreateFrame("FRAME", "CommDKPConfigReasonDropDown", CommDKP.UIConfig, "CommunityDKPUIDropDownMenuTemplate") + CommDKP.UIConfig.TeamViewChangerDropDown = LibDD:Create_UIDropDownMenu("CommDKPConfigReasonDropDown", CommDKP.UIConfig); --CommDKP.ConfigTab3.TeamManagementContainer.TeamListDropDown:ClearAllPoints() CommDKP.UIConfig.TeamViewChangerDropDown:SetPoint("BOTTOMLEFT", CommDKP.UIConfig, "BOTTOMLEFT", 340, 4) -- tooltip on mouseOver @@ -569,7 +571,7 @@ function CommDKP:CreateMenu() StaticPopup_Show ("RAID_IN_PROGRESS") end else - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end end diff --git a/Core.lua b/Core.lua index 05379951..151a666f 100644 --- a/Core.lua +++ b/Core.lua @@ -169,7 +169,7 @@ core.EncounterList = { -- Event IDs must be in the exact same order as core core.CommDKPUI = {} -- global storing entire Configuration UI to hide/show UI core.MonVersion = "v3.2.9"; core.BuildNumber = 30209; -core.ReleaseNumber = 70 +core.ReleaseNumber = 71 core.defaultTable = "__default"; core.SemVer = core.MonVersion.."-r"..tostring(core.ReleaseNumber); core.UpgradeSchema = false; diff --git a/Localization/Localization.cn.lua b/Localization/Localization.cn.lua index 4c8907a0..f98de8c6 100644 --- a/Localization/Localization.cn.lua +++ b/Localization/Localization.cn.lua @@ -900,10 +900,10 @@ if GetLocale() == "zhCN" then MIGRATIONCOMPLETED = "Migration complete.|n|nPlease disable MonolithDKP and /reload the UI.", --TODO TRANSLATE: --TODO TRANSLATE: - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Localization/Localization.de.lua b/Localization/Localization.de.lua index 8358e59a..42bc6e55 100644 --- a/Localization/Localization.de.lua +++ b/Localization/Localization.de.lua @@ -894,10 +894,10 @@ if GetLocale() == "deDE" then MIGRATIONCOMPLETED = "Migration abgeschlossen.|n|nBitte deaktivieren Sie MonolithDKP und laden Sie das UI neu. (/reload)", --TODO TRANSLATE: - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Localization/Localization.en.lua b/Localization/Localization.en.lua index 131b082d..704c32df 100644 --- a/Localization/Localization.en.lua +++ b/Localization/Localization.en.lua @@ -875,10 +875,10 @@ core.L = { MIGRATIONCANCELED = "Migration canceled.|n|nPlease disable MonolithDKP and /reload the UI if you want to continue with CommunityDKP without using your current tables and settings.", MIGRATIONCOMPLETED = "Migration complete.|n|nPlease disable MonolithDKP and /reload the UI.", - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Localization/Localization.es.lua b/Localization/Localization.es.lua index f7a4c31d..240e5761 100644 --- a/Localization/Localization.es.lua +++ b/Localization/Localization.es.lua @@ -898,10 +898,10 @@ if GetLocale() == "esES" or GetLocale() == "esMX" then MIGRATIONCOMPLETED = "Migration complete.|n|nPlease disable MonolithDKP and /reload the UI.", --TODO TRANSLATE: --TODO TRANSLATE: - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Localization/Localization.fr.lua b/Localization/Localization.fr.lua index ca8cff42..cabce009 100644 --- a/Localization/Localization.fr.lua +++ b/Localization/Localization.fr.lua @@ -945,10 +945,10 @@ if GetLocale() == "frFR" then MIGRATIONCOMPLETED = "Migration réussie.|n|nVeuillez désactiver MonolithDKP et recharger votre interface (/reload).", --TODO TRANSLATE: --TODO TRANSLATE: - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Localization/Localization.kr.lua b/Localization/Localization.kr.lua index 4a50cbcc..84522570 100644 --- a/Localization/Localization.kr.lua +++ b/Localization/Localization.kr.lua @@ -897,10 +897,10 @@ if GetLocale() == "koKR" then MIGRATIONCOMPLETED = "Migration complete.|n|nPlease disable MonolithDKP and /reload the UI.", --TODO TRANSLATE: --TODO TRANSLATE: - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Localization/Localization.ru.lua b/Localization/Localization.ru.lua index 40372fa1..b69f1f9a 100644 --- a/Localization/Localization.ru.lua +++ b/Localization/Localization.ru.lua @@ -956,10 +956,10 @@ if GetLocale() == "ruRU" then MIGRATIONCOMPLETED = "Миграция завершена.|n|nПожалуйста отключите MonolithDKP и перезагрузите интерфейс.", --TODO TRANSLATE: - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Localization/Localization.se.lua b/Localization/Localization.se.lua index df87a00f..2dddc537 100644 --- a/Localization/Localization.se.lua +++ b/Localization/Localization.se.lua @@ -808,10 +808,10 @@ core.L = { MIGRATIONCOMPLETED = "Migration complete.|n|nPlease disable MonolithDKP and /reload the UI.", --TODO TRANSLATE: - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Localization/Localization.tw.lua b/Localization/Localization.tw.lua index 53584eaf..798237ec 100644 --- a/Localization/Localization.tw.lua +++ b/Localization/Localization.tw.lua @@ -899,10 +899,10 @@ if GetLocale() == "zhTW" then MIGRATIONCOMPLETED = "Migration complete.|n|nPlease disable MonolithDKP and /reload the UI.", --TODO TRANSLATE: --TODO TRANSLATE: - CHANGELOG1 = "CommunityDKP - v3.2.9-r70-bcc", + CHANGELOG1 = "CommunityDKP - v3.2.9-r71-bcc", CHANGELOG2 = " - updated ACE to its latest alpha version", CHANGELOG3 = " - added LibUIDropDownMenu-4.0 to avoid taint issue", - CHANGELOG4 = "", + CHANGELOG4 = " - actually read the lib documentation and fixed dropdowns", CHANGELOG5 = "", CHANGELOG6 = "", CHANGELOG7 = "", diff --git a/Modules/AdjustDKP.lua b/Modules/AdjustDKP.lua index 10782cc0..957f57dc 100644 --- a/Modules/AdjustDKP.lua +++ b/Modules/AdjustDKP.lua @@ -211,7 +211,8 @@ function CommDKP:AdjustDKPTab_Create() -- Reason DROPDOWN box -- Create the dropdown, and configure its appearance - CommDKP.ConfigTab2.reasonDropDown = CreateFrame("FRAME", "CommDKPConfigReasonDropDown", CommDKP.ConfigTab2, "CommunityDKPUIDropDownMenuTemplate") + CommDKP.ConfigTab2.reasonDropDown = LibDD:Create_UIDropDownMenu("CommDKPConfigReasonDropDown", CommDKP.ConfigTab2); + --CommDKP.ConfigTab2.reasonDropDown = CreateFrame("FRAME", "CommDKPConfigReasonDropDown", CommDKP.ConfigTab2, "CommunityDKPUIDropDownMenuTemplate") CommDKP.ConfigTab2.reasonDropDown:SetPoint("TOPLEFT", CommDKP.ConfigTab2.description, "BOTTOMLEFT", -23, -60) LibDD:UIDropDownMenu_SetWidth(CommDKP.ConfigTab2.reasonDropDown, 150) LibDD:UIDropDownMenu_SetText(CommDKP.ConfigTab2.reasonDropDown, L["SELECTREASON"]) @@ -266,7 +267,7 @@ function CommDKP:AdjustDKPTab_Create() CommDKP.ConfigTab2.otherReason:Hide(); end - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end CommDKP.ConfigTab2.reasonDropDown:SetScript("OnEnter", function(self) @@ -327,7 +328,8 @@ function CommDKP:AdjustDKPTab_Create() -- Boss Killed Dropdown - Hidden unless "Boss Kill Bonus" or "New Boss Kill Bonus" is selected -- Killing a boss on the list will auto select that boss - CommDKP.ConfigTab2.BossKilledDropdown = CreateFrame("FRAME", "CommDKPBossKilledDropdown", CommDKP.ConfigTab2, "CommunityDKPUIDropDownMenuTemplate") + --CommDKP.ConfigTab2.BossKilledDropdown = CreateFrame("FRAME", "CommDKPBossKilledDropdown", CommDKP.ConfigTab2, "CommunityDKPUIDropDownMenuTemplate") + CommDKP.ConfigTab2.BossKilledDropdown = LibDD:Create_UIDropDownMenu("CommDKPBossKilledDropdown", CommDKP.ConfigTab2); CommDKP.ConfigTab2.BossKilledDropdown:SetPoint("TOPLEFT", CommDKP.ConfigTab2.reasonDropDown, "BOTTOMLEFT", 0, 2) CommDKP.ConfigTab2.BossKilledDropdown:Hide() LibDD:UIDropDownMenu_SetWidth(CommDKP.ConfigTab2.BossKilledDropdown, 210) @@ -429,7 +431,7 @@ function CommDKP:AdjustDKPTab_Create() CommDKP.ConfigTab2.reasonDropDown:SetValue(L["BOSSKILLBONUS"]) end LibDD:UIDropDownMenu_SetText(CommDKP.ConfigTab2.BossKilledDropdown, core.CurrentRaidZone..": "..core.LastKilledBoss) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end -- Add DKP Edit Box diff --git a/Modules/Award.lua b/Modules/Award.lua index 3ab3e7d2..f2c63e8d 100644 --- a/Modules/Award.lua +++ b/Modules/Award.lua @@ -315,7 +315,8 @@ local function AwardConfirm_Create() f.teamHeader:SetPoint("TOPLEFT", f, "TOPLEFT", 120, -60); f.teamHeader:SetText(L["TEAM"]..":") - f.team = CreateFrame("FRAME", "CommDKPAwardConfirmPlayerDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + --f.team = CreateFrame("FRAME", "CommDKPAwardConfirmPlayerDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + f.team = LibDD:Create_UIDropDownMenu("CommDKPAwardConfirmPlayerDropDown", f); f.team:SetPoint("LEFT", f.teamHeader, "RIGHT", -15, 0) LibDD:UIDropDownMenu_SetWidth(f.team, 150) LibDD:UIDropDownMenu_JustifyText(f.team, "LEFT") @@ -330,7 +331,8 @@ local function AwardConfirm_Create() f.playerHeader:SetPoint("TOPRIGHT", f.teamHeader, "BOTTOMRIGHT", 0, -10); f.playerHeader:SetText(L["PLAYER"]..":") - f.player = CreateFrame("FRAME", "CommDKPAwardConfirmPlayerDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + --f.player = CreateFrame("FRAME", "CommDKPAwardConfirmPlayerDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + f.player = LibDD:Create_UIDropDownMenu("CommDKPAwardConfirmPlayerDropDown", f); f.player:SetPoint("LEFT", f.playerHeader, "RIGHT", -15, 0) LibDD:UIDropDownMenu_SetWidth(f.player, 150) LibDD:UIDropDownMenu_JustifyText(f.player, "LEFT") @@ -410,7 +412,8 @@ local function AwardConfirm_Create() f.bossHeader:SetPoint("TOPRIGHT", f.costHeader, "BOTTOMRIGHT", 0, -10); f.bossHeader:SetText(L["BOSS"]..":") - f.bossDropDown = CreateFrame("FRAME", "CommDKPAwardConfirmBossDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + --f.bossDropDown = CreateFrame("FRAME", "CommDKPAwardConfirmBossDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + f.bossDropDown = LibDD:Create_UIDropDownMenu("CommDKPAwardConfirmBossDropDown", f); f.bossDropDown:SetPoint("LEFT", f.bossHeader, "RIGHT", -15, -2) LibDD:UIDropDownMenu_SetWidth(f.bossDropDown, 150) LibDD:UIDropDownMenu_JustifyText(f.bossDropDown, "LEFT") @@ -425,7 +428,8 @@ local function AwardConfirm_Create() f.zoneHeader:SetPoint("TOPRIGHT", f.bossHeader, "BOTTOMRIGHT", 0, -10); f.zoneHeader:SetText(L["ZONE"]..":") - f.zoneDropDown = CreateFrame("FRAME", "CommDKPAwardConfirmBossDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + --f.zoneDropDown = CreateFrame("FRAME", "CommDKPAwardConfirmBossDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + f.zoneDropDown = LibDD:Create_UIDropDownMenu("CommDKPAwardConfirmBossDropDown", f); f.zoneDropDown:SetPoint("LEFT", f.zoneHeader, "RIGHT", -15, -2) LibDD:UIDropDownMenu_SetWidth(f.zoneDropDown, 150) LibDD:UIDropDownMenu_JustifyText(f.zoneDropDown, "LEFT") @@ -628,19 +632,19 @@ function CommDKP:AwardConfirm(player, cost, boss, zone, loot, reassign) function core.AwardConfirm.player:SetValue(newValue, arg2) ---- PLAYER dropdown function if player ~= newValue then player = newValue end LibDD:UIDropDownMenu_SetText(core.AwardConfirm.player, arg2) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end function core.AwardConfirm.bossDropDown:SetValue(newValue) ---- BOSS dropdown function LibDD:UIDropDownMenu_SetText(core.AwardConfirm.bossDropDown, newValue) curBoss = newValue; - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end function core.AwardConfirm.zoneDropDown:SetValue(newValue) ---- ZONE dropdown function LibDD:UIDropDownMenu_SetText(core.AwardConfirm.zoneDropDown, newValue) curZone = newValue; - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end core.AwardConfirm.yesButton:SetScript("OnClick", function() -- Run when "Yes" is clicked diff --git a/Modules/DKPHistory.lua b/Modules/DKPHistory.lua index 9930180f..548f68d7 100644 --- a/Modules/DKPHistory.lua +++ b/Modules/DKPHistory.lua @@ -79,7 +79,8 @@ function CommDKP:DKPHistoryFilterBox_Create() -- Create the dropdown, and configure its appearance if not filterDropdown then - filterDropdown = CreateFrame("FRAME", "CommDKPDKPHistoryFilterNameDropDown", CommDKP.ConfigTab6, "CommunityDKPUIDropDownMenuTemplate") + --filterDropdown = CreateFrame("FRAME", "CommDKPDKPHistoryFilterNameDropDown", CommDKP.ConfigTab6, "CommunityDKPUIDropDownMenuTemplate") + filterDropdown = LibDD:Create_UIDropDownMenu("CommDKPDKPHistoryFilterNameDropDown", CommDKP.ConfigTab6); end -- Create and bind the initialization function to the dropdown menu @@ -151,7 +152,7 @@ function CommDKP:DKPHistoryFilterBox_Create() end CommDKP:DKPHistory_Update(true) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end end diff --git a/Modules/LootHistory.lua b/Modules/LootHistory.lua index eafebc6c..c2452d82 100644 --- a/Modules/LootHistory.lua +++ b/Modules/LootHistory.lua @@ -174,7 +174,8 @@ function CommDKP:CreateSortBox() -- Create the dropdown, and configure its appearance if not sortDropdown then - sortDropdown = CreateFrame("FRAME", "CommDKPConfigFilterNameDropDown", CommDKP.ConfigTab5, "CommunityDKPUIDropDownMenuTemplate") + --sortDropdown = CreateFrame("FRAME", "CommDKPConfigFilterNameDropDown", CommDKP.ConfigTab5, "CommunityDKPUIDropDownMenuTemplate") + sortDropdown = LibDD:Create_UIDropDownMenu("CommDKPConfigFilterNameDropDown", CommDKP.ConfigTab5); end -- Create and bind the initialization function to the dropdown menu @@ -238,7 +239,7 @@ function CommDKP:CreateSortBox() -- level 2 to handle players and items elseif (level or 2) == 2 then - if UIDROPDOWNMENU_MENU_VALUE == L["PLAYERS"] then + if L_UIDROPDOWNMENU_MENU_VALUE == L["PLAYERS"] then for i=1, ceil(#PlayerList/displayLimit) do local max = i*displayLimit; @@ -253,7 +254,7 @@ function CommDKP:CreateSortBox() LibDD:UIDropDownMenu_AddButton(dropDownMenuItem, level) end - elseif UIDROPDOWNMENU_MENU_VALUE == L["ITEMS"] then + elseif L_UIDROPDOWNMENU_MENU_VALUE == L["ITEMS"] then for i=1, ceil(#ItemList/displayLimit) do local max = i*displayLimit; @@ -272,7 +273,7 @@ function CommDKP:CreateSortBox() else -- level 3 dropDownMenuItem.func = self.FilterSetValue - if UIDROPDOWNMENU_MENU_VALUE == L["PLAYERS"] then + if L_UIDROPDOWNMENU_MENU_VALUE == L["PLAYERS"] then --for i=playersRange[menuList], playersRange[menuList]+(displayLimit-1) do -- depending on menuList value from higher level this should give @@ -302,7 +303,7 @@ function CommDKP:CreateSortBox() end end - elseif UIDROPDOWNMENU_MENU_VALUE == L["ITEMS"] then + elseif L_UIDROPDOWNMENU_MENU_VALUE == L["ITEMS"] then for i=1+(menuList-1)*displayLimit, 1+(menuList-1)*displayLimit+(displayLimit-1) do if ItemList[i] then @@ -371,7 +372,7 @@ function CommDKP:CreateSortBox() CommDKP:LootHistory_Update(newValue) end - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end end diff --git a/Modules/ManageEntries.lua b/Modules/ManageEntries.lua index ca766de2..227b64c4 100644 --- a/Modules/ManageEntries.lua +++ b/Modules/ManageEntries.lua @@ -643,7 +643,8 @@ function CommDKP:ManageEntries() ---------------------------------- -- rank select dropDownMenu ---------------------------------- - CommDKP.ConfigTab3.GuildRankDropDown = CreateFrame("FRAME", "CommDKPConfigReasonDropDown", CommDKP.ConfigTab3, "CommunityDKPUIDropDownMenuTemplate") + --CommDKP.ConfigTab3.GuildRankDropDown = CreateFrame("FRAME", "CommDKPConfigReasonDropDown", CommDKP.ConfigTab3, "CommunityDKPUIDropDownMenuTemplate") + CommDKP.ConfigTab3.GuildRankDropDown = LibDD:Create_UIDropDownMenu("CommDKPConfigReasonDropDown", CommDKP.ConfigTab3); CommDKP.ConfigTab3.GuildRankDropDown:SetPoint("TOPLEFT", CommDKP.ConfigTab3.add_raid_to_table, "BOTTOMLEFT", -17, -15) CommDKP.ConfigTab3.GuildRankDropDown:SetScript("OnEnter", function(self) @@ -690,7 +691,7 @@ function CommDKP:ManageEntries() LibDD:UIDropDownMenu_SetText(CommDKP.ConfigTab3.GuildRankDropDown, L["SELECTRANK"]) end - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end ---------------------------------- @@ -1016,7 +1017,8 @@ function CommDKP:ManageEntries() ---------------------------------- -- Drop down with lists of teams ---------------------------------- - CommDKP.ConfigTab3.TeamListDropDown = CreateFrame("FRAME", "CommDKPConfigReasonDropDown", CommDKP.ConfigTab3, "CommunityDKPUIDropDownMenuTemplate") + --CommDKP.ConfigTab3.TeamListDropDown = CreateFrame("FRAME", "CommDKPConfigReasonDropDown", CommDKP.ConfigTab3, "CommunityDKPUIDropDownMenuTemplate") + CommDKP.ConfigTab3.TeamListDropDown = LibDD:Create_UIDropDownMenu("CommDKPConfigReasonDropDown", CommDKP.ConfigTab3); --CommDKP.ConfigTab3.TeamManagementContainer.TeamListDropDown:ClearAllPoints() CommDKP.ConfigTab3.TeamListDropDown:SetPoint("BOTTOMLEFT", CommDKP.ConfigTab3.TeamHeader, "BOTTOMLEFT", 0, -50) -- tooltip on mouseOver @@ -1071,7 +1073,7 @@ function CommDKP:ManageEntries() LibDD:UIDropDownMenu_SetText(CommDKP.ConfigTab3.TeamListDropDown, L["TEAMSELECT"]) end - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end ---------------------------------- @@ -1130,7 +1132,7 @@ function CommDKP:ManageEntries() LibDD:UIDropDownMenu_SetText(CommDKP.ConfigTab3.TeamListDropDown, L["TEAMSELECT"]) selectedTeam = nil selectedTeamIndex = nil - CloseDropDownMenus() + LibDD:CloseDropDownMenus() self:ClearFocus() self:SetText("") end @@ -1204,7 +1206,7 @@ function CommDKP:ManageEntries() LibDD:UIDropDownMenu_SetText(CommDKP.ConfigTab3.TeamListDropDown, L["TEAMSELECT"]) selectedTeam = nil selectedTeamIndex = nil - CloseDropDownMenus() + LibDD:CloseDropDownMenus() else StaticPopupDialogs["NOT_GUILD_MASTER"] = { text = L["NOTGUILDMASTER"], @@ -1252,7 +1254,7 @@ function CommDKP:ManageEntries() CommDKP:AddNewTeamToGuild() CommDKP.ConfigTab3.TeamNameInput:SetText("") LibDD:UIDropDownMenu_SetText(CommDKP.ConfigTab3.TeamListDropDown, L["TEAMSELECT"]) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end, timeout = 0, whileDead = true, diff --git a/Modules/Modes/DKPModesMain.lua b/Modules/Modes/DKPModesMain.lua index addbe1e7..2cdf3d22 100644 --- a/Modules/Modes/DKPModesMain.lua +++ b/Modules/Modes/DKPModesMain.lua @@ -52,7 +52,8 @@ function CommDKP:DKPModes_Main() end - f.DKPModesMain.ModesDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + --f.DKPModesMain.ModesDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + f.DKPModesMain.ModesDropDown = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f.DKPModesMain); -- Create and bind the initialization function to the dropdown menu LibDD:UIDropDownMenu_Initialize(f.DKPModesMain.ModesDropDown, function(self, level, menuList) @@ -202,7 +203,7 @@ function CommDKP:DKPModes_Main() end LibDD:UIDropDownMenu_SetText(f.DKPModesMain.ModesDropDown, LocalMode) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.DKPModesMain.ModesDropDown:SetScript("OnEnter", function(self) @@ -221,7 +222,8 @@ function CommDKP:DKPModes_Main() f.DKPModesMain.ModeHeader:SetText(L["DKPMODES"]) -- Rounding DROPDOWN box - f.DKPModesMain.RoundDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + --f.DKPModesMain.RoundDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + f.DKPModesMain.RoundDropDown = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f.DKPModesMain); -- Create and bind the initialization function to the dropdown menu LibDD:UIDropDownMenu_Initialize(f.DKPModesMain.RoundDropDown, function(self, level, menuList) @@ -249,7 +251,7 @@ function CommDKP:DKPModes_Main() function f.DKPModesMain.RoundDropDown:SetValue(newValue) core.DB.modes.rounding = newValue; LibDD:UIDropDownMenu_SetText(f.DKPModesMain.RoundDropDown, newValue) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.DKPModesMain.RoundDropDown:SetScript("OnLeave", function(self) @@ -271,7 +273,8 @@ function CommDKP:DKPModes_Main() f.DKPModesMain.RoundHeader:SetText(L["DKPROUNDING"]) -- MAX Bid button behavior - f.DKPModesMain.MaxBidBehaviorDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + --f.DKPModesMain.MaxBidBehaviorDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + f.DKPModesMain.MaxBidBehaviorDropDown = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f.DKPModesMain); -- Create and bind the initialization function to the dropdown menu LibDD:UIDropDownMenu_Initialize(f.DKPModesMain.MaxBidBehaviorDropDown, function(self, level, menuList) @@ -301,7 +304,7 @@ function CommDKP:DKPModes_Main() else LibDD:UIDropDownMenu_SetText(f.DKPModesMain.MaxBidBehaviorDropDown, L["MAXBIDBEHAVIORMIN"]) end - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.DKPModesMain.MaxBidBehaviorDropDown:SetScript("OnLeave", function(self) @@ -385,7 +388,8 @@ function CommDKP:DKPModes_Main() f.DKPModesMain.AntiSnipe.Header:SetText(L["ANTISNIPE"]) -- Channels DROPDOWN box - f.DKPModesMain.ChannelsDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + --f.DKPModesMain.ChannelsDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + f.DKPModesMain.ChannelsDropDown = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f.DKPModesMain); -- Create and bind the initialization function to the dropdown menu LibDD:UIDropDownMenu_Initialize(f.DKPModesMain.ChannelsDropDown, function(self, level, menuList) @@ -418,7 +422,7 @@ function CommDKP:DKPModes_Main() end LibDD:UIDropDownMenu_SetText(f.DKPModesMain.ChannelsDropDown, "Open Channels") - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.DKPModesMain.ChannelsDropDown:SetScript("OnEnter", function(self) @@ -438,7 +442,8 @@ function CommDKP:DKPModes_Main() -- Cost Auto Update Value DROPDOWN box if not core.DB.modes.CostSelection then core.DB.modes.CostSelection = "Second Bidder" end - f.DKPModesMain.CostSelection = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + --f.DKPModesMain.CostSelection = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + f.DKPModesMain.CostSelection = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f.DKPModesMain); f.DKPModesMain.CostSelection:SetPoint("TOPLEFT", f.DKPModesMain.ChannelsDropDown, "BOTTOMLEFT", 0, -10) local LocalCostSel; @@ -483,7 +488,7 @@ function CommDKP:DKPModes_Main() end LibDD:UIDropDownMenu_SetText(f.DKPModesMain.CostSelection, LocalCostSel) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.DKPModesMain.CostSelection:SetScript("OnEnter", function(self) @@ -565,8 +570,8 @@ function CommDKP:DKPModes_Main() end -- ZeroSum Type DROPDOWN box - f.DKPModesMain.ZeroSumType = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") - + --f.DKPModesMain.ZeroSumType = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + f.DKPModesMain.ZeroSumType = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f.DKPModesMain); -- Create and bind the initialization function to the dropdown menu LibDD:UIDropDownMenu_Initialize(f.DKPModesMain.ZeroSumType, function(self, level, menuList) @@ -606,7 +611,7 @@ function CommDKP:DKPModes_Main() end LibDD:UIDropDownMenu_SetText(f.DKPModesMain.ZeroSumType, newValue) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.DKPModesMain.ZeroSumType:SetScript("OnEnter", function(self) @@ -630,8 +635,8 @@ function CommDKP:DKPModes_Main() end -- Item Cost Value DROPDOWN box - f.DKPModesMain.ItemCostDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") - + --f.DKPModesMain.ItemCostDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain, "CommunityDKPUIDropDownMenuTemplate") + f.DKPModesMain.ItemCostDropDown = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f.DKPModesMain); -- Create and bind the initialization function to the dropdown menu LibDD:UIDropDownMenu_Initialize(f.DKPModesMain.ItemCostDropDown, function(self, level, menuList) @@ -670,7 +675,7 @@ function CommDKP:DKPModes_Main() end - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.DKPModesMain.ItemCostDropDown:SetScript("OnEnter", function(self) @@ -823,7 +828,8 @@ function CommDKP:DKPModes_Main() core.DB.modes.RollMode = "Default" end - f.DKPModesMain.RollContainer.RollBiddingModeDropdown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain.RollContainer, "CommunityDKPUIDropDownMenuTemplate") + --f.DKPModesMain.RollContainer.RollBiddingModeDropdown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f.DKPModesMain.RollContainer, "CommunityDKPUIDropDownMenuTemplate") + f.DKPModesMain.RollContainer.RollBiddingModeDropdown = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f.DKPModesMain.RollContainer); LibDD:UIDropDownMenu_Initialize( f.DKPModesMain.RollContainer.RollBiddingModeDropdown, @@ -875,7 +881,7 @@ function CommDKP:DKPModes_Main() f.DKPModesMain.RollContainer.maxKarma.Header:Show() end LibDD:UIDropDownMenu_SetText(f.DKPModesMain.RollContainer.RollBiddingModeDropdown, core.DB.modes.RollMode); - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.DKPModesMain.RollContainer.RollBiddingModeDropdown:SetScript( diff --git a/Modules/Options.lua b/Modules/Options.lua index 3fd51341..47a8114e 100644 --- a/Modules/Options.lua +++ b/Modules/Options.lua @@ -1377,7 +1377,8 @@ function CommDKP:Options() end) -- Chatframe Selection - CommDKP.ConfigTab4.ChatFrame = CreateFrame("FRAME", "CommDKPChatFrameSelectDropDown", CommDKP.ConfigTab4, "CommunityDKPUIDropDownMenuTemplate") + --CommDKP.ConfigTab4.ChatFrame = CreateFrame("FRAME", "CommDKPChatFrameSelectDropDown", CommDKP.ConfigTab4, "CommunityDKPUIDropDownMenuTemplate") + CommDKP.ConfigTab4.ChatFrame = LibDD:Create_UIDropDownMenu("CommDKPChatFrameSelectDropDown", CommDKP.ConfigTab4); if not core.DB.defaults.ChatFrames then core.DB.defaults.ChatFrames = {} end LibDD:UIDropDownMenu_Initialize(CommDKP.ConfigTab4.ChatFrame, function(self, level, menuList) @@ -1403,7 +1404,7 @@ function CommDKP:Options() function CommDKP.ConfigTab4.ChatFrame:SetValue(arg1) core.DB.defaults.ChatFrames[arg1] = not core.DB.defaults.ChatFrames[arg1] - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end diff --git a/Modules/Sync.lua b/Modules/Sync.lua index 18826621..eda4e7b2 100644 --- a/Modules/Sync.lua +++ b/Modules/Sync.lua @@ -208,7 +208,7 @@ function CommDKP_BroadcastFull_Init() function core.Broadcast.player:SetValue(newValue, arg2) ---- PLAYER dropdown function if player ~= newValue then player = newValue end LibDD:UIDropDownMenu_SetText(core.Broadcast.player, arg2) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end core.Broadcast.confirmButton:SetScript("OnClick", function() @@ -377,7 +377,8 @@ function CommDKP_BroadcastFull_Create() GameTooltip:Hide() end) - f.player = CreateFrame("FRAME", "CommDKPAwardConfirmPlayerDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + --f.player = CreateFrame("FRAME", "CommDKPAwardConfirmPlayerDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + f.player = LibDD:Create_UIDropDownMenu("CommDKPAwardConfirmPlayerDropDown", f); f.player:SetPoint("TOPRIGHT", f.tocontainer, "TOPRIGHT", 5, -7) LibDD:UIDropDownMenu_SetWidth(f.player, 150) LibDD:UIDropDownMenu_JustifyText(f.player, "LEFT") diff --git a/Modules/exportDKP.lua b/Modules/exportDKP.lua index b416fc53..f857efb6 100644 --- a/Modules/exportDKP.lua +++ b/Modules/exportDKP.lua @@ -280,7 +280,8 @@ function CommDKP:ExportBox_Show(text) -- Format DROPDOWN box local CurFormat; - f.FormatDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + --f.FormatDropDown = CreateFrame("FRAME", "CommDKPModeSelectDropDown", f, "CommunityDKPUIDropDownMenuTemplate") + f.FormatDropDown = LibDD:Create_UIDropDownMenu("CommDKPModeSelectDropDown", f); f.FormatDropDown:SetPoint("BOTTOMLEFT", f, "BOTTOMLEFT", 20, 55) LibDD:UIDropDownMenu_SetWidth(f.FormatDropDown, 100) LibDD:UIDropDownMenu_SetText(f.FormatDropDown, "Select Format") @@ -312,7 +313,7 @@ function CommDKP:ExportBox_Show(text) f.desc:SetText(ExportDefinition); LibDD:UIDropDownMenu_SetText(f.FormatDropDown, CurFormat) - CloseDropDownMenus() + LibDD:CloseDropDownMenus() end f.FormatDropDown:SetScript("OnEnter", function(self)