X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fthird_party%2Ficu%2Fsource%2Fi18n%2Frbt_set.cpp;h=59c489d6e58996910596ba16ecb5950849064474;hb=4a1a0bdd01eef90b0826a0e761d3379d3715c10f;hp=1553c4f041953b17d60a4e6fde3826753f9cc08f;hpb=b1be5ca53587d23e7aeb77b26861fdc0a181ffd8;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/third_party/icu/source/i18n/rbt_set.cpp b/src/third_party/icu/source/i18n/rbt_set.cpp index 1553c4f..59c489d 100644 --- a/src/third_party/icu/source/i18n/rbt_set.cpp +++ b/src/third_party/icu/source/i18n/rbt_set.cpp @@ -1,6 +1,6 @@ /* ********************************************************************** - * Copyright (C) 1999-2008, International Business Machines + * Copyright (C) 1999-2011, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************** * Date Name Description @@ -14,6 +14,7 @@ #include "unicode/unistr.h" #include "unicode/uniset.h" +#include "unicode/utf16.h" #include "rbt_set.h" #include "rbt_rule.h" #include "cmemory.h" @@ -21,7 +22,7 @@ U_CDECL_BEGIN static void U_CALLCONV _deleteRule(void *rule) { - delete (U_NAMESPACE_QUALIFIER TransliterationRule *)rule; + delete (icu::TransliterationRule *)rule; } U_CDECL_END @@ -90,7 +91,7 @@ UnicodeString& _escape(const UnicodeString &source, UnicodeString &target) { for (int32_t i = 0; i < source.length(); ) { UChar32 ch = source.char32At(i); - i += UTF_CHAR_LENGTH(ch); + i += U16_LENGTH(ch); if (ch < 0x09 || (ch > 0x0A && ch < 0x20)|| ch > 0x7E) { if (ch <= 0xFFFF) { target += "\\u"; @@ -133,10 +134,10 @@ inline void _debugOut(const char* msg, TransliterationRule* rule, // Fill the precontext and postcontext with the patterns of the rules // that are masking one another. -static void maskingError(const U_NAMESPACE_QUALIFIER TransliterationRule& rule1, - const U_NAMESPACE_QUALIFIER TransliterationRule& rule2, +static void maskingError(const icu::TransliterationRule& rule1, + const icu::TransliterationRule& rule2, UParseError& parseError) { - U_NAMESPACE_QUALIFIER UnicodeString r; + icu::UnicodeString r; int32_t len; parseError.line = parseError.offset = -1; @@ -416,7 +417,7 @@ UBool TransliterationRuleSet::transliterate(Replaceable& text, } } // No match or partial match from any rule - pos.start += UTF_CHAR_LENGTH(text.char32At(pos.start)); + pos.start += U16_LENGTH(text.char32At(pos.start)); _debugOut("no match", NULL, text, pos); return TRUE; }