diff options
| author | Anton Yabchinskiy <arn@bestmx.ru> | 2014-12-09 17:51:14 +0300 |
|---|---|---|
| committer | Anton Yabchinskiy <arn@bestmx.ru> | 2014-12-09 17:51:14 +0300 |
| commit | ff755f93eb86e3f7f6801918457ca77a3001671b (patch) | |
| tree | 58d6def002b427db665a504f08d25eae335bd9d9 /core | |
| parent | d45be7d9f43046365fcfbf97420f9eca636c51e7 (diff) | |
| parent | be4e40e90a5a322f6a7cec4893854ef5b15db600 (diff) | |
Merge branch 'master' of http://github.com/okamstudio/godot
Diffstat (limited to 'core')
| -rw-r--r-- | core/io/resource_format_xml.cpp | 6 | ||||
| -rw-r--r-- | core/variant.h | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/core/io/resource_format_xml.cpp b/core/io/resource_format_xml.cpp index 2a79e6647d..75384d4ab6 100644 --- a/core/io/resource_format_xml.cpp +++ b/core/io/resource_format_xml.cpp @@ -193,6 +193,7 @@ Error ResourceInteractiveLoaderXML::close_tag(const String& p_name) { void ResourceInteractiveLoaderXML::unquote(String& p_str) { + p_str=p_str.strip_edges().replace("\"","").xml_unescape(); /*p_str=p_str.strip_edges(); @@ -1851,7 +1852,10 @@ void ResourceFormatSaverXMLInstance::escape(String& p_str) { for (int i=1;i<32;i++) { char chr[2]={i,0}; - p_str=p_str.replace(chr,"&#"+String::num(i)+";"); + const char hexn[16]={'0','1','2','3','4','5','6','7','8','9','a','b','c','d','e','f'}; + const char hex[8]={'&','#','0','0',hexn[i>>4],hexn[i&0xf],';',0}; + + p_str=p_str.replace(chr,hex); } diff --git a/core/variant.h b/core/variant.h index f651e38352..9109f4ad08 100644 --- a/core/variant.h +++ b/core/variant.h @@ -358,7 +358,7 @@ public: static String get_operator_name(Operator p_op); static void evaluate(const Operator& p_op,const Variant& p_a, const Variant& p_b,Variant &r_ret,bool &r_valid); - static _FORCE_INLINE_ Variant evaluate(Operator& p_op,const Variant& p_a, const Variant& p_b) { + static _FORCE_INLINE_ Variant evaluate(const Operator& p_op,const Variant& p_a, const Variant& p_b) { bool valid=true; Variant res; |