mirror of
https://github.com/Bluewhale1337/ElvUIModernized.git
synced 2026-07-27 08:24:44 +00:00
Merge branch 'master' into dev
This commit is contained in:
@@ -500,7 +500,6 @@ function EditBoxSetCursorPosition(self, pos)
|
|||||||
|
|
||||||
text = sub(text, 0, 1)
|
text = sub(text, 0, 1)
|
||||||
self:HighlightText(0, 1)
|
self:HighlightText(0, 1)
|
||||||
self:Insert(nbsp)
|
|
||||||
self:Insert(text)
|
self:Insert(text)
|
||||||
self:HighlightText(0, 1)
|
self:HighlightText(0, 1)
|
||||||
self:Insert("")
|
self:Insert("")
|
||||||
|
|||||||
@@ -3,6 +3,6 @@
|
|||||||
]]
|
]]
|
||||||
|
|
||||||
SLASH_RELOADUI1 = "/rl"
|
SLASH_RELOADUI1 = "/rl"
|
||||||
SLASH_RELOADUI2 = "/reload"
|
SLASH_RELOADUI2 = "/reloadui"
|
||||||
SLASH_RELOADUI3 = "/reloadui"
|
SLASH_RELOADUI3 = "/reload"
|
||||||
SlashCmdList.RELOADUI = ReloadUI
|
SlashCmdList.RELOADUI = ReloadUI
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
--Cache global variables
|
|
||||||
--Lua functions
|
|
||||||
local setmetatable, getmetatable = setmetatable, getmetatable
|
local setmetatable, getmetatable = setmetatable, getmetatable
|
||||||
local pairs, type = pairs, type
|
local pairs, type = pairs, type
|
||||||
local table = table
|
local table = table
|
||||||
|
|||||||
@@ -413,61 +413,6 @@ function B:ResetSlotAlphaForBags(f)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
local function buttonOnClick(button, ignoreModifiers)
|
|
||||||
if not button then button = arg1 end
|
|
||||||
|
|
||||||
--KeyRing special case code
|
|
||||||
if this:GetParent():GetID() == KEYRING_CONTAINER then
|
|
||||||
KeyRingItemButton_OnClick(button, ignoreModifiers)
|
|
||||||
return
|
|
||||||
end
|
|
||||||
|
|
||||||
if button == "LeftButton" then
|
|
||||||
if IsControlKeyDown() and not ignoreModifiers then
|
|
||||||
DressUpItemLink(GetContainerItemLink(this:GetParent():GetID(), this:GetID()))
|
|
||||||
elseif IsShiftKeyDown() and not ignoreModifiers then
|
|
||||||
if ChatFrameEditBox:IsShown() then
|
|
||||||
ChatFrameEditBox:Insert(GetContainerItemLink(this:GetParent():GetID(), this:GetID()))
|
|
||||||
else
|
|
||||||
local texture, itemCount, locked = GetContainerItemInfo(this:GetParent():GetID(), this:GetID())
|
|
||||||
if not locked then
|
|
||||||
this.SplitStack = function(button, split)
|
|
||||||
SplitContainerItem(button:GetParent():GetID(), button:GetID(), split)
|
|
||||||
end
|
|
||||||
OpenStackSplitFrame(this.count, this, "BOTTOMRIGHT", "TOPRIGHT")
|
|
||||||
end
|
|
||||||
end
|
|
||||||
else
|
|
||||||
PickupContainerItem(this:GetParent():GetID(), this:GetID())
|
|
||||||
StackSplitFrame:Hide()
|
|
||||||
end
|
|
||||||
else
|
|
||||||
if IsControlKeyDown() and not ignoreModifiers then
|
|
||||||
return
|
|
||||||
elseif IsShiftKeyDown() and MerchantFrame:IsShown() and not ignoreModifiers then
|
|
||||||
this.SplitStack = function(button, split)
|
|
||||||
SplitContainerItem(button:GetParent():GetID(), button:GetID(), split)
|
|
||||||
MerchantItemButton_OnClick("LeftButton")
|
|
||||||
end
|
|
||||||
OpenStackSplitFrame(this.count, this, "BOTTOMRIGHT", "TOPRIGHT")
|
|
||||||
elseif MerchantFrame:IsShown() and MerchantFrame.selectedTab == 2 then
|
|
||||||
-- Don't sell the item if the buyback tab is selected
|
|
||||||
return
|
|
||||||
else
|
|
||||||
UseContainerItem(this:GetParent():GetID(), this:GetID())
|
|
||||||
StackSplitFrame:Hide()
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
local function buttonOnDragStart()
|
|
||||||
buttonOnClick("LeftButton", 1)
|
|
||||||
end
|
|
||||||
|
|
||||||
local function buttonOnReceiveDrag()
|
|
||||||
buttonOnClick("LeftButton", 1)
|
|
||||||
end
|
|
||||||
|
|
||||||
function B:Layout(isBank)
|
function B:Layout(isBank)
|
||||||
if E.private.bags.enable ~= true then return end
|
if E.private.bags.enable ~= true then return end
|
||||||
local f = self:GetContainerFrame(isBank)
|
local f = self:GetContainerFrame(isBank)
|
||||||
@@ -585,10 +530,6 @@ function B:Layout(isBank)
|
|||||||
f.Bags[bagID][slotID]:SetNormalTexture("")
|
f.Bags[bagID][slotID]:SetNormalTexture("")
|
||||||
f.Bags[bagID][slotID]:SetCheckedTexture("")
|
f.Bags[bagID][slotID]:SetCheckedTexture("")
|
||||||
|
|
||||||
f.Bags[bagID][slotID]:SetScript("OnClick", buttonOnClick)
|
|
||||||
f.Bags[bagID][slotID]:SetScript("OnDragStart", buttonOnDragStart)
|
|
||||||
f.Bags[bagID][slotID]:SetScript("OnReceiveDrag", buttonOnReceiveDrag)
|
|
||||||
|
|
||||||
f.Bags[bagID][slotID].Count = _G[f.Bags[bagID][slotID]:GetName().."Count"]
|
f.Bags[bagID][slotID].Count = _G[f.Bags[bagID][slotID]:GetName().."Count"]
|
||||||
f.Bags[bagID][slotID].Count:ClearAllPoints()
|
f.Bags[bagID][slotID].Count:ClearAllPoints()
|
||||||
E:Point(f.Bags[bagID][slotID].Count, "BOTTOMRIGHT", 0, 2)
|
E:Point(f.Bags[bagID][slotID].Count, "BOTTOMRIGHT", 0, 2)
|
||||||
|
|||||||
@@ -157,6 +157,15 @@ function B:EnhanceColorPicker()
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--Set OnUpdate script to handle update limiter
|
||||||
|
this:SetScript("OnUpdate", HandleUpdateLimiter)
|
||||||
|
end)
|
||||||
|
|
||||||
|
hooksecurefunc(ColorPickerFrame, "SetFrameLevel", function(self, level)
|
||||||
|
for _, child in ipairs({self:GetChildren()}) do
|
||||||
|
child:SetFrameLevel(level + 1)
|
||||||
|
end
|
||||||
end)
|
end)
|
||||||
|
|
||||||
--Memory Fix, Colorpicker will call the this.func() 100x per second, causing fps/memory issues,
|
--Memory Fix, Colorpicker will call the this.func() 100x per second, causing fps/memory issues,
|
||||||
@@ -233,7 +242,8 @@ function B:EnhanceColorPicker()
|
|||||||
b = CreateFrame("Button", "ColorPPClass", ColorPickerFrame, "UIPanelButtonTemplate")
|
b = CreateFrame("Button", "ColorPPClass", ColorPickerFrame, "UIPanelButtonTemplate")
|
||||||
b:SetText(CLASS)
|
b:SetText(CLASS)
|
||||||
S:HandleButton(b)
|
S:HandleButton(b)
|
||||||
E:Size(b, 80, 22)
|
E:Width(b, 80)
|
||||||
|
E:Height(b, 22)
|
||||||
E:Point(b, "TOP", "ColorPPCopy", "BOTTOMRIGHT", 0, -7)
|
E:Point(b, "TOP", "ColorPPCopy", "BOTTOMRIGHT", 0, -7)
|
||||||
|
|
||||||
b:SetScript("OnClick", function()
|
b:SetScript("OnClick", function()
|
||||||
@@ -249,7 +259,8 @@ function B:EnhanceColorPicker()
|
|||||||
b = CreateFrame("Button", "ColorPPPaste", ColorPickerFrame, "UIPanelButtonTemplate")
|
b = CreateFrame("Button", "ColorPPPaste", ColorPickerFrame, "UIPanelButtonTemplate")
|
||||||
b:SetText(L["Paste"])
|
b:SetText(L["Paste"])
|
||||||
S:HandleButton(b)
|
S:HandleButton(b)
|
||||||
E:Size(b, 60, 22)
|
E:Width(b, 60)
|
||||||
|
E:Height(b, 22)
|
||||||
E:Point(b, "TOPLEFT", "ColorPPCopy", "TOPRIGHT", 2, 0)
|
E:Point(b, "TOPLEFT", "ColorPPCopy", "TOPRIGHT", 2, 0)
|
||||||
b:Disable() -- enable when something has been copied
|
b:Disable() -- enable when something has been copied
|
||||||
|
|
||||||
@@ -268,7 +279,8 @@ function B:EnhanceColorPicker()
|
|||||||
b = CreateFrame("Button", "ColorPPDefault", ColorPickerFrame, "UIPanelButtonTemplate")
|
b = CreateFrame("Button", "ColorPPDefault", ColorPickerFrame, "UIPanelButtonTemplate")
|
||||||
b:SetText(DEFAULTS)
|
b:SetText(DEFAULTS)
|
||||||
S:HandleButton(b)
|
S:HandleButton(b)
|
||||||
E:Size(b, 80, 22)
|
E:Width(b, 80)
|
||||||
|
E:Height(b, 22)
|
||||||
E:Point(b, "TOPLEFT", "ColorPPClass", "BOTTOMLEFT", 0, -7)
|
E:Point(b, "TOPLEFT", "ColorPPClass", "BOTTOMLEFT", 0, -7)
|
||||||
b:Disable() -- enable when something has been copied
|
b:Disable() -- enable when something has been copied
|
||||||
b:SetScript("OnHide", function()
|
b:SetScript("OnHide", function()
|
||||||
|
|||||||
@@ -42,20 +42,48 @@ local function SkinButton(f, strip, noTemplate)
|
|||||||
end
|
end
|
||||||
|
|
||||||
local function SkinDropdownPullout(self)
|
local function SkinDropdownPullout(self)
|
||||||
if self.obj.pullout.frame.template and self.obj.pullout.slider.template then return end
|
if self and self.obj then
|
||||||
|
local pullout = self.obj.pullout
|
||||||
|
local dropdown = self.obj.dropdown
|
||||||
|
|
||||||
if not self.obj.pullout.frame.template then
|
if pullout and pullout.frame then
|
||||||
E:SetTemplate(self.obj.pullout.frame, "Default", true)
|
if pullout.frame.template and pullout.slider.template then return end
|
||||||
end
|
|
||||||
|
|
||||||
if not self.obj.pullout.slider.template then
|
if not pullout.frame.template then
|
||||||
E:SetTemplate(self.obj.pullout.slider, "Default")
|
E:SetTemplate(pullout.frame, "Default", true)
|
||||||
E:Point(self.obj.pullout.slider, "TOPRIGHT", self.obj.pullout.frame, "TOPRIGHT", -10, -10)
|
end
|
||||||
E:Point(self.obj.pullout.slider, "BOTTOMRIGHT", self.obj.pullout.frame, "BOTTOMRIGHT", -10, 10)
|
|
||||||
if self.obj.pullout.slider:GetThumbTexture() then
|
if not pullout.slider.template then
|
||||||
self.obj.pullout.slider:SetThumbTexture(E.media.normTex)
|
E:SetTemplate(pullout.slider, "Default")
|
||||||
self.obj.pullout.slider:GetThumbTexture():SetVertexColor(unpack(E.media.rgbvaluecolor))
|
E:Point(pullout.slider, "TOPRIGHT", pullout.frame, "TOPRIGHT", -10, -10)
|
||||||
E:Size(self.obj.pullout.slider:GetThumbTexture(), 10, 14)
|
E:Point(pullout.slider, "BOTTOMRIGHT", pullout.frame, "BOTTOMRIGHT", -10, 10)
|
||||||
|
if pullout.slider:GetThumbTexture() then
|
||||||
|
pullout.slider:SetThumbTexture(E.media.normTex)
|
||||||
|
pullout.slider:GetThumbTexture():SetVertexColor(unpack(E.media.rgbvaluecolor))
|
||||||
|
E:Size(pullout.slider:GetThumbTexture(), 10, 14)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
elseif dropdown then
|
||||||
|
E:SetTemplate(dropdown, "Default", true)
|
||||||
|
|
||||||
|
if dropdown.slider then
|
||||||
|
E:SetTemplate(dropdown.slider, "Default")
|
||||||
|
E:Point(dropdown.slider, "TOPRIGHT", dropdown, "TOPRIGHT", -10, -10)
|
||||||
|
E:Point(dropdown.slider, "BOTTOMRIGHT", dropdown, "BOTTOMRIGHT", -10, 10)
|
||||||
|
|
||||||
|
if dropdown.slider:GetThumbTexture() then
|
||||||
|
dropdown.slider:SetThumbTexture(E.media.normTex)
|
||||||
|
dropdown.slider:GetThumbTexture():SetVertexColor(unpack(E.media.rgbvaluecolor))
|
||||||
|
E:Size(dropdown.slider:GetThumbTexture(), 10, 14)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if TYPE == "LSM30_Sound" then
|
||||||
|
local frame = self.obj.frame
|
||||||
|
local width = frame:GetWidth()
|
||||||
|
E:Point(dropdown, "TOPLEFT", frame, "BOTTOMLEFT")
|
||||||
|
E:Point(dropdown, "TOPRIGHT", frame, "BOTTOMRIGHT", width < 160 and (160 - width) or 30, 0)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -81,6 +109,7 @@ function S:SkinAce3()
|
|||||||
SkinButton(widget.button)
|
SkinButton(widget.button)
|
||||||
S:HandleScrollBar(widget.scrollBar)
|
S:HandleScrollBar(widget.scrollBar)
|
||||||
E:Point(widget.scrollBar, "RIGHT", frame, "RIGHT", 0 -4)
|
E:Point(widget.scrollBar, "RIGHT", frame, "RIGHT", 0 -4)
|
||||||
|
|
||||||
E:Point(scrollBG, "TOPRIGHT", widget.scrollBar, "TOPLEFT", -2, 19)
|
E:Point(scrollBG, "TOPRIGHT", widget.scrollBar, "TOPLEFT", -2, 19)
|
||||||
E:Point(scrollBG, "BOTTOMLEFT", widget.button, "TOPLEFT")
|
E:Point(scrollBG, "BOTTOMLEFT", widget.button, "TOPLEFT")
|
||||||
E:Point(widget.scrollFrame, "BOTTOMRIGHT", scrollBG, "BOTTOMRIGHT", -4, 8)
|
E:Point(widget.scrollFrame, "BOTTOMRIGHT", scrollBG, "BOTTOMRIGHT", -4, 8)
|
||||||
@@ -117,7 +146,7 @@ function S:SkinAce3()
|
|||||||
E:CreateBackdrop(frame, "Default")
|
E:CreateBackdrop(frame, "Default")
|
||||||
end
|
end
|
||||||
|
|
||||||
E:Point(frame.backdrop, "TOPLEFT", 15, -2)
|
E:Point(frame.backdrop, "TOPLEFT", 17, -2)
|
||||||
E:Point(frame.backdrop, "BOTTOMRIGHT", -21, 0)
|
E:Point(frame.backdrop, "BOTTOMRIGHT", -21, 0)
|
||||||
|
|
||||||
widget.label:ClearAllPoints()
|
widget.label:ClearAllPoints()
|
||||||
@@ -128,6 +157,9 @@ function S:SkinAce3()
|
|||||||
E:Point(button, "RIGHT", frame.backdrop, "RIGHT", -2, 0)
|
E:Point(button, "RIGHT", frame.backdrop, "RIGHT", -2, 0)
|
||||||
button:SetParent(frame.backdrop)
|
button:SetParent(frame.backdrop)
|
||||||
|
|
||||||
|
text:ClearAllPoints()
|
||||||
|
E:Point(text, "RIGHT", frame.backdrop, "RIGHT", -26, 2)
|
||||||
|
E:Point(text, "LEFT", frame.backdrop, "LEFT", 2, 0)
|
||||||
text:SetParent(frame.backdrop)
|
text:SetParent(frame.backdrop)
|
||||||
|
|
||||||
HookScript(button, "OnClick", SkinDropdownPullout)
|
HookScript(button, "OnClick", SkinDropdownPullout)
|
||||||
@@ -176,30 +208,7 @@ function S:SkinAce3()
|
|||||||
button:SetParent(frame.backdrop)
|
button:SetParent(frame.backdrop)
|
||||||
text:SetParent(frame.backdrop)
|
text:SetParent(frame.backdrop)
|
||||||
|
|
||||||
HookScript(button, "OnClick", function(self)
|
HookScript(button, "OnClick", SkinDropdownPullout)
|
||||||
local dropdown = self.obj.dropdown
|
|
||||||
if dropdown then
|
|
||||||
E:SetTemplate(dropdown, "Default", true)
|
|
||||||
if dropdown.slider then
|
|
||||||
E:SetTemplate(dropdown.slider, "Transparent")
|
|
||||||
E:Point(dropdown.slider, "TOPRIGHT", dropdown, "TOPRIGHT", -10, -10)
|
|
||||||
E:Point(dropdown.slider, "BOTTOMRIGHT", dropdown, "BOTTOMRIGHT", -10, 10)
|
|
||||||
|
|
||||||
if dropdown.slider:GetThumbTexture() then
|
|
||||||
dropdown.slider:SetThumbTexture(E.media.normTex)
|
|
||||||
dropdown.slider:GetThumbTexture():SetVertexColor(unpack(E.media.rgbvaluecolor))
|
|
||||||
E:Size(dropdown.slider:GetThumbTexture(), 10, 14)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
if TYPE == "LSM30_Sound" then
|
|
||||||
local frame = self.obj.frame
|
|
||||||
local width = frame:GetWidth()
|
|
||||||
E:Point(dropdown, "TOPLEFT", frame, "BOTTOMLEFT")
|
|
||||||
E:Point(dropdown, "TOPRIGHT", frame, "BOTTOMRIGHT", width < 160 and (160 - width) or 30, 0)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end)
|
|
||||||
elseif TYPE == "EditBox" then
|
elseif TYPE == "EditBox" then
|
||||||
local frame = widget.editbox
|
local frame = widget.editbox
|
||||||
local button = widget.button
|
local button = widget.button
|
||||||
@@ -235,23 +244,6 @@ function S:SkinAce3()
|
|||||||
E:SetInside(frame.backdrop)
|
E:SetInside(frame.backdrop)
|
||||||
|
|
||||||
widget.text:SetParent(frame.backdrop)
|
widget.text:SetParent(frame.backdrop)
|
||||||
elseif TYPE == "Keybinding" then
|
|
||||||
local button = widget.button
|
|
||||||
local msgframe = widget.msgframe
|
|
||||||
local msg = widget.msgframe.msg
|
|
||||||
|
|
||||||
SkinButton(button)
|
|
||||||
|
|
||||||
E:StripTextures(msgframe)
|
|
||||||
E:CreateBackdrop(msgframe, "Default", true)
|
|
||||||
E:SetInside(msgframe.backdrop)
|
|
||||||
msgframe:SetToplevel(true)
|
|
||||||
|
|
||||||
msg:ClearAllPoints()
|
|
||||||
E:Point(msg, "LEFT", 10, 0)
|
|
||||||
E:Point(msg, "RIGHT", -10, 0)
|
|
||||||
msg:SetJustifyV("MIDDLE")
|
|
||||||
E:Width(msg, msg:GetWidth() + 10)
|
|
||||||
elseif TYPE == "Slider" then
|
elseif TYPE == "Slider" then
|
||||||
local frame = widget.slider
|
local frame = widget.slider
|
||||||
local editbox = widget.editbox
|
local editbox = widget.editbox
|
||||||
@@ -273,6 +265,23 @@ function S:SkinAce3()
|
|||||||
|
|
||||||
E:Point(lowtext, "TOPLEFT", frame, "BOTTOMLEFT", 2, -2)
|
E:Point(lowtext, "TOPLEFT", frame, "BOTTOMLEFT", 2, -2)
|
||||||
E:Point(hightext, "TOPRIGHT", frame, "BOTTOMRIGHT", -2, -2)
|
E:Point(hightext, "TOPRIGHT", frame, "BOTTOMRIGHT", -2, -2)
|
||||||
|
elseif TYPE == "Keybinding" then
|
||||||
|
local button = widget.button
|
||||||
|
local msgframe = widget.msgframe
|
||||||
|
local msg = widget.msgframe.msg
|
||||||
|
|
||||||
|
SkinButton(button)
|
||||||
|
|
||||||
|
E:StripTextures(msgframe)
|
||||||
|
E:CreateBackdrop(msgframe, "Default", true)
|
||||||
|
E:SetInside(msgframe.backdrop)
|
||||||
|
msgframe:SetToplevel(true)
|
||||||
|
|
||||||
|
msg:ClearAllPoints()
|
||||||
|
E:Point(msg, "LEFT", 10, 0)
|
||||||
|
E:Point(msg, "RIGHT", -10, 0)
|
||||||
|
msg:SetJustifyV("MIDDLE")
|
||||||
|
E:Width(msg, msg:GetWidth() + 10)
|
||||||
elseif (TYPE == "ColorPicker" or TYPE == "ColorPicker-ElvUI") then
|
elseif (TYPE == "ColorPicker" or TYPE == "ColorPicker-ElvUI") then
|
||||||
local frame = widget.frame
|
local frame = widget.frame
|
||||||
local colorSwatch = widget.colorSwatch
|
local colorSwatch = widget.colorSwatch
|
||||||
@@ -286,6 +295,8 @@ function S:SkinAce3()
|
|||||||
E:Point(frame.backdrop, "LEFT", frame, "LEFT", 4, 0)
|
E:Point(frame.backdrop, "LEFT", frame, "LEFT", 4, 0)
|
||||||
frame.backdrop:SetBackdropColor(0, 0, 0, 0)
|
frame.backdrop:SetBackdropColor(0, 0, 0, 0)
|
||||||
frame.backdrop.SetBackdropColor = E.noop
|
frame.backdrop.SetBackdropColor = E.noop
|
||||||
|
frame.backdrop:SetBackdropBorderColor(1, 1, 1)
|
||||||
|
frame.backdrop.SetBackdropBorderColor = E.noop
|
||||||
|
|
||||||
colorSwatch:SetTexture(E.media.blankTex)
|
colorSwatch:SetTexture(E.media.blankTex)
|
||||||
colorSwatch:ClearAllPoints()
|
colorSwatch:ClearAllPoints()
|
||||||
@@ -370,20 +381,28 @@ function S:SkinAce3()
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if TYPE == "TabGroup" then
|
if TYPE == "TabGroup" then
|
||||||
local oldCreateTab = widget.CreateTab
|
local oldCreateTab = widget.CreateTab
|
||||||
widget.CreateTab = function(self, id)
|
widget.CreateTab = function(self, id)
|
||||||
local tab = oldCreateTab(self, id)
|
local tab = oldCreateTab(self, id)
|
||||||
E:StripTextures(tab)
|
E:StripTextures(tab)
|
||||||
--[[tab.backdrop = CreateFrame("Frame", nil, tab)
|
tab.backdrop = CreateFrame("Frame", nil, tab)
|
||||||
E:SetTemplate(tab.backdrop, "Transparent")
|
E:SetTemplate(tab.backdrop, "Transparent")
|
||||||
tab.backdrop:SetFrameLevel(tab:GetFrameLevel() - 1)
|
E:Point(tab.backdrop, "TOPLEFT", 10, -3)
|
||||||
E:Point(tab.backdrop, "TOPLEFT", 10, -3)
|
E:Point(tab.backdrop, "BOTTOMRIGHT", -10, 0)
|
||||||
E:Point(tab.backdrop, "BOTTOMRIGHT", -10, 0)--]]
|
|
||||||
|
|
||||||
return tab
|
HookScript(tab, "OnShow", function(self)
|
||||||
end
|
local tabFrame = tab:GetFrameLevel()
|
||||||
end
|
local tabBackdrop = tab.backdrop:GetFrameLevel()
|
||||||
|
|
||||||
|
if tabFrame <= tabBackdrop then
|
||||||
|
tab.backdrop:SetFrameLevel(tabFrame - 1)
|
||||||
|
end
|
||||||
|
end)
|
||||||
|
|
||||||
|
return tab
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
if widget.scrollbar then
|
if widget.scrollbar then
|
||||||
S:HandleScrollBar(widget.scrollbar)
|
S:HandleScrollBar(widget.scrollbar)
|
||||||
@@ -410,4 +429,4 @@ local f = CreateFrame("Frame")
|
|||||||
f:RegisterEvent("ADDON_LOADED")
|
f:RegisterEvent("ADDON_LOADED")
|
||||||
f:SetScript("OnEvent", attemptSkin)
|
f:SetScript("OnEvent", attemptSkin)
|
||||||
|
|
||||||
S:AddCallback("Ace3", attemptSkin)
|
S:AddCallback("Ace3", attemptSkin)
|
||||||
|
|||||||
@@ -74,7 +74,7 @@ Constructor
|
|||||||
-------------------------------------------------------------------------------]]
|
-------------------------------------------------------------------------------]]
|
||||||
local function Constructor()
|
local function Constructor()
|
||||||
local name = "AceGUI30Button" .. AceGUI:GetNextWidgetNum(Type)
|
local name = "AceGUI30Button" .. AceGUI:GetNextWidgetNum(Type)
|
||||||
local frame = CreateFrame("Button", name, UIParent, "UIPanelButtonTemplate2")
|
local frame = CreateFrame("Button", name, UIParent, "UIPanelButtonTemplate")
|
||||||
frame:Hide()
|
frame:Hide()
|
||||||
|
|
||||||
frame:EnableMouse(true)
|
frame:EnableMouse(true)
|
||||||
|
|||||||
@@ -722,7 +722,7 @@ do
|
|||||||
self.text = text
|
self.text = text
|
||||||
text.obj = self
|
text.obj = self
|
||||||
text:ClearAllPoints()
|
text:ClearAllPoints()
|
||||||
text:SetPoint("RIGHT", right, "RIGHT" ,-46, 2)
|
text:SetPoint("RIGHT", right, "RIGHT" ,-43, 2)
|
||||||
text:SetPoint("LEFT", left, "LEFT", 25, 2)
|
text:SetPoint("LEFT", left, "LEFT", 25, 2)
|
||||||
|
|
||||||
local label = frame:CreateFontString(nil,"OVERLAY","GameFontNormalSmall")
|
local label = frame:CreateFontString(nil,"OVERLAY","GameFontNormalSmall")
|
||||||
|
|||||||
@@ -64,9 +64,9 @@ if not AceGUIEditBoxInsertLink then
|
|||||||
|
|
||||||
hooksecurefunc("SetItemRef", function(link, text, button)
|
hooksecurefunc("SetItemRef", function(link, text, button)
|
||||||
if IsShiftKeyDown() then
|
if IsShiftKeyDown() then
|
||||||
if sub(link, 1, 6) == "player" then
|
if strsub(link,1,6) == "player" then
|
||||||
local name = sub(link, 8)
|
local name = strsub(link,8)
|
||||||
if name and name ~= "" then
|
if name and (strlen(name) > 0) then
|
||||||
return _G.AceGUIEditBoxInsertLink(name)
|
return _G.AceGUIEditBoxInsertLink(name)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
@@ -116,7 +116,7 @@ if not AceGUIEditBoxInsertLink then
|
|||||||
if id <= MAX_SPELLS and (not drag) and IsShiftKeyDown() then
|
if id <= MAX_SPELLS and (not drag) and IsShiftKeyDown() then
|
||||||
local spellName, subSpellName = GetSpellName(id, SpellBookFrame.bookType)
|
local spellName, subSpellName = GetSpellName(id, SpellBookFrame.bookType)
|
||||||
if spellName and not IsSpellPassive(id, SpellBookFrame.bookType) then
|
if spellName and not IsSpellPassive(id, SpellBookFrame.bookType) then
|
||||||
if subSpellName and subSpellName ~= "" then
|
if subSpellName and (strlen(subSpellName) > 0) then
|
||||||
_G.AceGUIEditBoxInsertLink(spellName.."("..subSpellName..")")
|
_G.AceGUIEditBoxInsertLink(spellName.."("..subSpellName..")")
|
||||||
else
|
else
|
||||||
_G.AceGUIEditBoxInsertLink(spellName)
|
_G.AceGUIEditBoxInsertLink(spellName)
|
||||||
|
|||||||
@@ -192,7 +192,7 @@ local function Constructor()
|
|||||||
local name = "AceGUI30KeybindingButton" .. AceGUI:GetNextWidgetNum(Type)
|
local name = "AceGUI30KeybindingButton" .. AceGUI:GetNextWidgetNum(Type)
|
||||||
|
|
||||||
local frame = CreateFrame("Frame", nil, UIParent)
|
local frame = CreateFrame("Frame", nil, UIParent)
|
||||||
local button = CreateFrame("Button", name, frame, "UIPanelButtonTemplate2")
|
local button = CreateFrame("Button", name, frame, "UIPanelButtonTemplate")
|
||||||
|
|
||||||
button:EnableMouse(true)
|
button:EnableMouse(true)
|
||||||
button:EnableMouseWheel(false)
|
button:EnableMouseWheel(false)
|
||||||
|
|||||||
@@ -113,7 +113,7 @@ if not AceGUIMultiLineEditBoxInsertLink then
|
|||||||
if id <= MAX_SPELLS and (not drag) and IsShiftKeyDown() then
|
if id <= MAX_SPELLS and (not drag) and IsShiftKeyDown() then
|
||||||
local spellName, subSpellName = GetSpellName(id, SpellBookFrame.bookType)
|
local spellName, subSpellName = GetSpellName(id, SpellBookFrame.bookType)
|
||||||
if spellName and not IsSpellPassive(id, SpellBookFrame.bookType) then
|
if spellName and not IsSpellPassive(id, SpellBookFrame.bookType) then
|
||||||
if subSpellName and subSpellName ~= "" then
|
if subSpellName and (strlen(subSpellName) > 0) then
|
||||||
_G.AceGUIMultiLineEditBoxInsertLink(spellName.."("..subSpellName..")")
|
_G.AceGUIMultiLineEditBoxInsertLink(spellName.."("..subSpellName..")")
|
||||||
else
|
else
|
||||||
_G.AceGUIMultiLineEditBoxInsertLink(spellName)
|
_G.AceGUIMultiLineEditBoxInsertLink(spellName)
|
||||||
|
|||||||
@@ -139,6 +139,7 @@ local methods = {
|
|||||||
self.disabled = disabled
|
self.disabled = disabled
|
||||||
if disabled then
|
if disabled then
|
||||||
self.slider:EnableMouse(false)
|
self.slider:EnableMouse(false)
|
||||||
|
self.slider:GetThumbTexture():SetDesaturated(true) -- ElvUI
|
||||||
self.label:SetTextColor(.5, .5, .5)
|
self.label:SetTextColor(.5, .5, .5)
|
||||||
self.hightext:SetTextColor(.5, .5, .5)
|
self.hightext:SetTextColor(.5, .5, .5)
|
||||||
self.lowtext:SetTextColor(.5, .5, .5)
|
self.lowtext:SetTextColor(.5, .5, .5)
|
||||||
@@ -148,6 +149,7 @@ local methods = {
|
|||||||
self.editbox:ClearFocus()
|
self.editbox:ClearFocus()
|
||||||
else
|
else
|
||||||
self.slider:EnableMouse(true)
|
self.slider:EnableMouse(true)
|
||||||
|
self.slider:GetThumbTexture():SetDesaturated(false) -- ElvUI
|
||||||
self.label:SetTextColor(1, .82, 0)
|
self.label:SetTextColor(1, .82, 0)
|
||||||
self.hightext:SetTextColor(1, 1, 1)
|
self.hightext:SetTextColor(1, 1, 1)
|
||||||
self.lowtext:SetTextColor(1, 1, 1)
|
self.lowtext:SetTextColor(1, 1, 1)
|
||||||
|
|||||||
Reference in New Issue
Block a user