Skip to content

Commit

Permalink
feat: Hardcore support using new libs
Browse files Browse the repository at this point in the history
Updated menus to use new libs, and fixed an backdrop color. Moved version to hardcore era.
  • Loading branch information
Linden-Ryuujin committed Sep 10, 2023
1 parent f2ed594 commit 54f64e1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
5 changes: 3 additions & 2 deletions TrackingEye.lua
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
--====================================================================================================================================================

local TrackingEye = LibStub("AceAddon-3.0"):NewAddon("TrackingEye", "AceConsole-3.0", "AceEvent-3.0")
local LibDD = LibStub:GetLibrary("LibUIDropDownMenu-4.0")

-- Setup minimap button
local LDB = LibStub("LibDataBroker-1.1"):NewDataObject("TrackingEyeData",
Expand Down Expand Up @@ -218,8 +219,8 @@ function TrackingEye:TargetMenu_Open()
end

-- I have added some custom code to LibUIDropDownMenu that handle an "attributes" entry using secure buttons for macro support.
local menuFrame = L_Create_UIDropDownMenu("TrackingEyeTargetMenu", UIParent)
L_EasyMenu(menu, menuFrame, "cursor", 0 , 0, "MENU");
local menuFrame = LibDD:Create_UIDropDownMenu("TrackingEyeTargetMenu", UIParent)
LibDD:EasyMenu(menu, menuFrame, "cursor", 0 , 0, "MENU");
end

------------------------------------------------------------------------------------------------------------------------------------------------------
Expand Down
4 changes: 2 additions & 2 deletions TrackingEye.toc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## Interface: 11307
## Interface: 11404
## Title: Tracking Eye
## Author: Linden Ryuujin
## Version: 2.0.1
## Version: 2.2.0

## SavedVariables: TrackingEyeDB
## OptionalDeps: Ace3, Masque, LibButtonGlow-1.0, LibActionButton-1.0, LibKeyBound-1.0, LibDBIcon-1.0, LibWindow-1.1, LibDualSpec-1.0
Expand Down
2 changes: 1 addition & 1 deletion libs/LibUIDropDownMenu/LibUIDropDownMenu.lua
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ local function creatre_DropDownList(name, parent)
--local fmb = _G[name.."MenuBackdrop"] or CreateFrame("Frame", name.."MenuBackdrop", f, BackdropTemplateMixin and "TooltipBackdropTemplate" or nil)
local fmb = _G[name.."MenuBackdrop"] or CreateFrame("Frame", name.."MenuBackdrop", f, BackdropTemplateMixin and "BackdropTemplate" or nil)
fmb:SetAllPoints()
fmb:SetBackdrop(BACKDROP_TOOLTIP_16_16_5555)
fmb:SetBackdrop(BACKDROP_TUTORIAL_16_16)
fmb:SetBackdropBorderColor(TOOLTIP_DEFAULT_COLOR.r, TOOLTIP_DEFAULT_COLOR.g, TOOLTIP_DEFAULT_COLOR.b)
fmb:SetBackdropColor(TOOLTIP_DEFAULT_BACKGROUND_COLOR.r, TOOLTIP_DEFAULT_BACKGROUND_COLOR.g, TOOLTIP_DEFAULT_BACKGROUND_COLOR.b)
f.MenuBackdrop = fmb
Expand Down

0 comments on commit 54f64e1

Please sign in to comment.