From 9ea934cd827dda12fc811e88ceb7488134f580d7 Mon Sep 17 00:00:00 2001 From: Ray Greenwell Date: Mon, 14 May 2007 20:47:33 +0000 Subject: [PATCH] Added support for recognizing "command://" urls. Sigh. So not standard. I suppose I could devise a whole system for registering protocols, and adding registered protocols to this regexp, but we'll never have another one of these and this is just easier for now. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4709 542714f4-19e9-0310-aa3c-eee0fc999fb1 --- src/as/com/threerings/util/StringUtil.as | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/as/com/threerings/util/StringUtil.as b/src/as/com/threerings/util/StringUtil.as index 96a313612..da446b21f 100644 --- a/src/as/com/threerings/util/StringUtil.as +++ b/src/as/com/threerings/util/StringUtil.as @@ -237,6 +237,7 @@ public class StringUtil /** A regular expression that finds URLs. */ protected static const URL_REGEXP :RegExp = - new RegExp("(http|https|ftp)://\\S+", "i"); + // recognize some standard protocols, plus 'command', which we use internally + new RegExp("(http|https|ftp|command)://\\S+", "i"); } }