sylvanaar / prat-3-0

Prat-3.0 is a chat enhancement addon for world of warcraft
https://www.curseforge.com/wow/addons/prat-3-0
GNU General Public License v3.0
25 stars 45 forks source link

9.0.1: Prat breaks the Pet Battle UI #145

Closed tflo closed 3 years ago

tflo commented 3 years ago

Prat breaks the lower part of the Pet Battle UI. See screenshot.

Screenshot of Wow (15-10-2020, 14-39-04)

This happens with Prat as only add-on.

ntowle commented 3 years ago

This is caused by a missing backdrop mixin on editbox frames in EditBox.lua's mod:SetBackdrop() function. Fix below:

  function mod:SetBackdrop()
    for _, frame in ipairs(self.frames) do
      if not frame.SetBackdrop then          --fix
        Mixin(frame, BackdropTemplateMixin)  --fix add these three lines
      end                                    --fix

      frame:SetBackdrop({
        bgFile = Media:Fetch("background", self.db.profile.background),
        edgeFile = Media:Fetch("border", self.db.profile.border),
        tile = true,
        tileSize = self.db.profile.tileSize,
        edgeSize = self.db.profile.edgeSize,
        insets = {
          left = self.db.profile.inset,
          right = self.db.profile.inset,
          top = self.db.profile.inset,
          bottom = self.db.profile.inset
        }
      })
      local c = self.db.profile.backgroundColor
      frame:SetBackdropColor(c.r, c.g, c.b, c.a)

      local c = self.db.profile.borderColor
      frame:SetBackdropBorderColor(c.r, c.g, c.b, c.a)
    end
  end
ntowle commented 3 years ago

Looks like #133 might also fix this if it was merged.

github-actions[bot] commented 3 years ago

This issue was flagged as stale