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

Unified Diff: core/fxcrt/fx_basic_utf.cpp

Issue 1832173003: Remove FX_DWORD from core/ and delete definition (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/fxcrt/fx_basic_plex.cpp ('k') | core/fxcrt/fx_bidi.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fxcrt/fx_basic_utf.cpp
diff --git a/core/fxcrt/fx_basic_utf.cpp b/core/fxcrt/fx_basic_utf.cpp
index 08b9ca6ba602f89021708bc2f078bc24e457f1ae..e1996999f89a5c37431cd0df747ca8fdc86fa048 100644
--- a/core/fxcrt/fx_basic_utf.cpp
+++ b/core/fxcrt/fx_basic_utf.cpp
@@ -10,7 +10,7 @@ void CFX_UTF8Decoder::Clear() {
m_Buffer.Clear();
m_PendingBytes = 0;
}
-void CFX_UTF8Decoder::AppendChar(FX_DWORD ch) {
+void CFX_UTF8Decoder::AppendChar(uint32_t ch) {
m_Buffer.AppendChar((FX_WCHAR)ch);
}
void CFX_UTF8Decoder::Input(uint8_t byte) {
@@ -44,20 +44,20 @@ void CFX_UTF8Decoder::Input(uint8_t byte) {
}
}
void CFX_UTF8Encoder::Input(FX_WCHAR unicode) {
- if ((FX_DWORD)unicode < 0x80) {
+ if ((uint32_t)unicode < 0x80) {
m_Buffer.AppendChar(unicode);
} else {
- if ((FX_DWORD)unicode >= 0x80000000) {
+ if ((uint32_t)unicode >= 0x80000000) {
return;
}
int nbytes = 0;
- if ((FX_DWORD)unicode < 0x800) {
+ if ((uint32_t)unicode < 0x800) {
nbytes = 2;
- } else if ((FX_DWORD)unicode < 0x10000) {
+ } else if ((uint32_t)unicode < 0x10000) {
nbytes = 3;
- } else if ((FX_DWORD)unicode < 0x200000) {
+ } else if ((uint32_t)unicode < 0x200000) {
nbytes = 4;
- } else if ((FX_DWORD)unicode < 0x4000000) {
+ } else if ((uint32_t)unicode < 0x4000000) {
nbytes = 5;
} else {
nbytes = 6;
« no previous file with comments | « core/fxcrt/fx_basic_plex.cpp ('k') | core/fxcrt/fx_bidi.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698