Quantcast

-What do you mean I can't link stuff in SPECIAL channels? Aren't I Special?

Xruptor [12-21-10 - 13:51]
-What do you mean I can't link stuff in SPECIAL channels?  Aren't I Special?
Filename
XanChat.lua
XanChat.toc
diff --git a/XanChat.lua b/XanChat.lua
index b0b0bd7..4256d26 100644
--- a/XanChat.lua
+++ b/XanChat.lua
@@ -183,6 +183,9 @@ function urlFilter(self, event, msg, author, ...)
 	if strfind(msg, "(%d%d?%d?)%.(%d%d?%d?)%.(%d%d?%d?)%.(%d%d?%d?)%s?") then
 		return false, gsub(msg, "(%d%d?%d?)%.(%d%d?%d?)%.(%d%d?%d?)%.(%d%d?%d?)%s?", doColor("%1.%2.%3.%4")), author, ...
 	end
+	if strfind(msg, "[wWhH][wWtT][wWtT][\46pP]%S+[^%p%s]") then
+		return false, gsub(msg, "[wWhH][wWtT][wWtT][\46pP]%S+[^%p%s]", doColor("%1")), author, ...
+	end
 end

 StaticPopupDialogs["LINKME"] = {
@@ -231,6 +234,13 @@ end

 SetItemRef = xanChat_URLRef

+ChatFrame_AddMessageEventFilter("CHAT_MSG_BATTLEGROUND_LEADER", urlFilter)
+ChatFrame_AddMessageEventFilter("CHAT_MSG_BN_CONVERSATION", urlFilter)
+ChatFrame_AddMessageEventFilter("CHAT_MSG_BN_WHISPER", urlFilter)
+ChatFrame_AddMessageEventFilter("CHAT_MSG_PARTY_LEADER", urlFilter)
+ChatFrame_AddMessageEventFilter("CHAT_MSG_RAID_LEADER", urlFilter)
+ChatFrame_AddMessageEventFilter("CHAT_MSG_RAID_WARNING", urlFilter)
+
 ChatFrame_AddMessageEventFilter("CHAT_MSG_GUILD", urlFilter)
 ChatFrame_AddMessageEventFilter("CHAT_MSG_OFFICER", urlFilter)
 ChatFrame_AddMessageEventFilter("CHAT_MSG_PARTY", urlFilter)
diff --git a/XanChat.toc b/XanChat.toc
index 0034ec9..21ae2a7 100644
--- a/XanChat.toc
+++ b/XanChat.toc
@@ -2,6 +2,6 @@
 ## Title: xanChat
 ## Notes: A very minimalistic chat modification addon.
 ## Author: Xruptor
-## Version: 1.6
+## Version: 1.7

 xanChat.lua