Skip to content

Commit f210031

Browse files
committed
Fixing error on theme creation (GH issue #307)
1 parent 167883a commit f210031

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Options/GridUtils.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -629,14 +629,14 @@ do
629629

630630
local function ShowDialog(message, textDefault, funcAccept, funcCancel, textAccept, textCancel)
631631
local t = StaticPopupDialogs["GRID2OPTIONS_GENERAL_DIALOG"]
632-
t.OnShow = function (self) if textDefault then self.editBox:SetText(textDefault) end; self:SetFrameStrata("TOOLTIP") end
632+
t.OnShow = function (self) if textDefault then (self.editBox or self:GetEditBox()):SetText(textDefault) end; self:SetFrameStrata("TOOLTIP") end
633633
t.OnHide = function(self) self:SetFrameStrata("DIALOG") end
634634
t.hasEditBox = textDefault and true or nil
635635
t.text = message
636636
t.button1 = funcAccept and (textAccept or ACCEPT) or nil
637637
t.button2 = funcCancel and (textCancel or CANCEL) or nil
638638
t.OnCancel = funcCancel
639-
t.OnAccept = funcAccept and function (self) funcAccept( textDefault and self.editBox:GetText() ) end or nil
639+
t.OnAccept = funcAccept and function (self) funcAccept( textDefault and (self.editBox or self:GetEditBox()):GetText() ) end or nil
640640
StaticPopup_Show ("GRID2OPTIONS_GENERAL_DIALOG")
641641
end
642642

0 commit comments

Comments
 (0)