Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(280)

Side by Side Diff: third_party/WebKit/WebCore/platform/text/TextEncoding.h

Issue 174528: japanese encoding webkit fixes for 3.0 branch (Closed) Base URL: svn://chrome-svn/chrome/branches/195/src/
Patch Set: Created 11 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 26 matching lines...) Expand all
37 class TextEncoding { 37 class TextEncoding {
38 public: 38 public:
39 TextEncoding() : m_name(0) { } 39 TextEncoding() : m_name(0) { }
40 TextEncoding(const char* name); 40 TextEncoding(const char* name);
41 TextEncoding(const String& name); 41 TextEncoding(const String& name);
42 42
43 bool isValid() const { return m_name; } 43 bool isValid() const { return m_name; }
44 const char* name() const { return m_name; } 44 const char* name() const { return m_name; }
45 const char* domName() const; // name exposed via DOM 45 const char* domName() const; // name exposed via DOM
46 bool usesVisualOrdering() const; 46 bool usesVisualOrdering() const;
47 #if !PLATFORM(CHROMIUM)
47 bool isJapanese() const; 48 bool isJapanese() const;
49 #endif
48 50
49 PassRefPtr<StringImpl> displayString(PassRefPtr<StringImpl> str) const 51 PassRefPtr<StringImpl> displayString(PassRefPtr<StringImpl> str) const
50 { 52 {
51 if (m_backslashAsCurrencySymbol == '\\' || !str) 53 if (m_backslashAsCurrencySymbol == '\\' || !str)
52 return str; 54 return str;
53 return str->replace('\\', m_backslashAsCurrencySymbol); 55 return str->replace('\\', m_backslashAsCurrencySymbol);
54 } 56 }
55 void displayBuffer(UChar* characters, unsigned len) const 57 void displayBuffer(UChar* characters, unsigned len) const
56 { 58 {
57 if (m_backslashAsCurrencySymbol == '\\') 59 if (m_backslashAsCurrencySymbol == '\\')
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 const TextEncoding& UTF16BigEndianEncoding(); 92 const TextEncoding& UTF16BigEndianEncoding();
91 const TextEncoding& UTF16LittleEndianEncoding(); 93 const TextEncoding& UTF16LittleEndianEncoding();
92 const TextEncoding& UTF32BigEndianEncoding(); 94 const TextEncoding& UTF32BigEndianEncoding();
93 const TextEncoding& UTF32LittleEndianEncoding(); 95 const TextEncoding& UTF32LittleEndianEncoding();
94 const TextEncoding& UTF8Encoding(); 96 const TextEncoding& UTF8Encoding();
95 const TextEncoding& WindowsLatin1Encoding(); 97 const TextEncoding& WindowsLatin1Encoding();
96 98
97 } // namespace WebCore 99 } // namespace WebCore
98 100
99 #endif // TextEncoding_h 101 #endif // TextEncoding_h
OLDNEW
« no previous file with comments | « third_party/WebKit/WebCore/loader/TextResourceDecoder.cpp ('k') | third_party/WebKit/WebCore/platform/text/TextEncoding.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698