Import mx's StringUtil.substitute() into our own StringUtil, as it's annoying
to have two StringUtils. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4475 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -23,8 +23,6 @@ package com.threerings.util {
|
|||||||
|
|
||||||
import mx.resources.ResourceBundle;
|
import mx.resources.ResourceBundle;
|
||||||
|
|
||||||
import mx.utils.StringUtil;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A message bundle provides an easy mechanism by which to obtain
|
* A message bundle provides an easy mechanism by which to obtain
|
||||||
* translated message strings from a resource bundle. It uses the {@link
|
* translated message strings from a resource bundle. It uses the {@link
|
||||||
@@ -180,7 +178,7 @@ public class MessageBundle
|
|||||||
return (key + args);
|
return (key + args);
|
||||||
}
|
}
|
||||||
|
|
||||||
return mx.utils.StringUtil.substitute(msg, args);
|
return StringUtil.substitute(msg, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -91,6 +91,14 @@ public class StringUtil
|
|||||||
return str;
|
return str;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Substitute "{n}" tokens for the corresponding passed-in arguments.
|
||||||
|
*/
|
||||||
|
public static function substitute (str :String, ... args) :String
|
||||||
|
{
|
||||||
|
return mx.utils.StringUtil.substitute(str, args);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Utility function that strips whitespace from the ends of a String.
|
* Utility function that strips whitespace from the ends of a String.
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user