Skip to content

Commit

Permalink
Fix bug loading on Shadowlands, also allows loading on BFA
Browse files Browse the repository at this point in the history
In Shadowlands one major API change was that frames no longer have a backdrop by default, so frames which are setting a backdrop need to inherit from 'BackdropTemplate'.
  • Loading branch information
jayotterbein committed Aug 15, 2020
1 parent 4eee160 commit f1c56da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion basicOptions.lua
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ local function newSlider(parent, cvar, minRange, maxRange, stepSize, getValue, s
slider.maxText:SetText(maxRange)
slider.text:SetText(label)

local valueBox = CreateFrame('editbox', nil, slider)
local valueBox = CreateFrame('editbox', nil, slider, DoesTemplateExist("BackdropTemplate") and "BackdropTemplate" or nil)
valueBox:SetPoint('TOP', slider, 'BOTTOM', 0, 0)
valueBox:SetSize(60, 14)
valueBox:SetFontObject(GameFontHighlightSmall)
Expand Down

1 comment on commit f1c56da

@Ketho
Copy link
Contributor

@Ketho Ketho commented on f1c56da Aug 15, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just this should be enough

local valueBox = CreateFrame('editbox', nil, slider, BackdropTemplateMixin and "BackdropTemplate")

https://github.com/Stanzilla/WoWUIBugs/wiki/9.0.1-Consolidated-UI-Changes#backdrops

Please sign in to comment.