From 85cb65b1ad511431c74bf8437153f74a7aeabdd6 Mon Sep 17 00:00:00 2001 From: James Whitehead II Date: Sun, 10 Aug 2008 18:38:57 +0000 Subject: [PATCH] Added code to check whether we're running on a wrath client or not --- WowLua.lua | 4 ++++ WowLua.xml | 6 +++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/WowLua.lua b/WowLua.lua index 6d329b2..a6e4698 100644 --- a/WowLua.lua +++ b/WowLua.lua @@ -5,6 +5,10 @@ WowLua is an interactive interpreter for World of Warcraft --------------------------------------------------------------------------]]-- +function IsWrathBuild() + return(tonumber(select(4, GetBuildInfo())) >= 30000) +end + WowLua = { VERSION = "WowLua 1.0 Interactive Interpreter", } diff --git a/WowLua.xml b/WowLua.xml index 5ad4549..30e73c1 100644 --- a/WowLua.xml +++ b/WowLua.xml @@ -506,7 +506,11 @@ WowLua.lastCursorPos = WowLua.cursorPos WowLua.cursorPos = self:GetCursorPosition() - ScrollingEdit_OnCursorChanged(self, x,y,w,h) + if IsWrathBuild() then + ScrollingEdit_OnCursorChanged(self,x,y,w,h) + else + ScrollingEdit_OnCursorChanged(x,y,w,h) + end WowLua:UpdateLineNums() WowLuaFrameEditScrollFrameScrollBar:SetValue(WowLuaFrameEditScrollFrame:GetVerticalScroll()) -- 1.7.9.5