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

Side by Side Diff: fpdfsdk/cfx_systemhandler.cpp

Issue 2347313002: Remove duplicated charset definitions (Closed)
Patch Set: Nits Created 4 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
« no previous file with comments | « core/fxge/win32/fx_win32_device.cpp ('k') | fpdfsdk/formfiller/cba_fontmap.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 PDFium Authors. All rights reserved. 1 // Copyright 2016 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #include "fpdfsdk/cfx_systemhandler.h" 7 #include "fpdfsdk/cfx_systemhandler.h"
8 8
9 #include <memory> 9 #include <memory>
10 10
11 #include "core/fpdfapi/fpdf_parser/include/cpdf_document.h" 11 #include "core/fpdfapi/fpdf_parser/include/cpdf_document.h"
12 #include "core/fxge/include/cfx_fontmapper.h" 12 #include "core/fxge/include/cfx_fontmapper.h"
13 #include "core/fxge/include/cfx_fontmgr.h" 13 #include "core/fxge/include/cfx_fontmgr.h"
14 #include "core/fxge/include/cfx_gemodule.h" 14 #include "core/fxge/include/cfx_gemodule.h"
15 #include "fpdfsdk/formfiller/cffl_formfiller.h" 15 #include "fpdfsdk/formfiller/cffl_formfiller.h"
16 #include "fpdfsdk/include/cpdfsdk_annot.h" 16 #include "fpdfsdk/include/cpdfsdk_annot.h"
17 #include "fpdfsdk/include/cpdfsdk_document.h" 17 #include "fpdfsdk/include/cpdfsdk_document.h"
18 #include "fpdfsdk/include/cpdfsdk_environment.h" 18 #include "fpdfsdk/include/cpdfsdk_environment.h"
19 #include "fpdfsdk/include/cpdfsdk_pageview.h" 19 #include "fpdfsdk/include/cpdfsdk_pageview.h"
20 #include "fpdfsdk/include/cpdfsdk_widget.h" 20 #include "fpdfsdk/include/cpdfsdk_widget.h"
21 21
22 namespace { 22 namespace {
23 23
24 int CharSet2CP(int charset) { 24 int CharSet2CP(int charset) {
25 if (charset == FXFONT_SHIFTJIS_CHARSET) 25 if (charset == FXFONT_SHIFTJIS_CHARSET)
26 return 932; 26 return 932;
27 if (charset == FXFONT_GB2312_CHARSET) 27 if (charset == FXFONT_GB2312_CHARSET)
28 return 936; 28 return 936;
29 if (charset == FXFONT_HANGEUL_CHARSET) 29 if (charset == FXFONT_HANGUL_CHARSET)
30 return 949; 30 return 949;
31 if (charset == FXFONT_CHINESEBIG5_CHARSET) 31 if (charset == FXFONT_CHINESEBIG5_CHARSET)
32 return 950; 32 return 950;
33 return 0; 33 return 0;
34 } 34 }
35 35
36 } // namespace 36 } // namespace
37 37
38 void CFX_SystemHandler::InvalidateRect(CPDFSDK_Widget* widget, FX_RECT rect) { 38 void CFX_SystemHandler::InvalidateRect(CPDFSDK_Widget* widget, FX_RECT rect) {
39 CPDFSDK_PageView* pPageView = widget->GetPageView(); 39 CPDFSDK_PageView* pPageView = widget->GetPageView();
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 return !!m_pEnv->IsSHIFTKeyDown(nFlag); 134 return !!m_pEnv->IsSHIFTKeyDown(nFlag);
135 } 135 }
136 136
137 bool CFX_SystemHandler::IsCTRLKeyDown(uint32_t nFlag) const { 137 bool CFX_SystemHandler::IsCTRLKeyDown(uint32_t nFlag) const {
138 return !!m_pEnv->IsCTRLKeyDown(nFlag); 138 return !!m_pEnv->IsCTRLKeyDown(nFlag);
139 } 139 }
140 140
141 bool CFX_SystemHandler::IsALTKeyDown(uint32_t nFlag) const { 141 bool CFX_SystemHandler::IsALTKeyDown(uint32_t nFlag) const {
142 return !!m_pEnv->IsALTKeyDown(nFlag); 142 return !!m_pEnv->IsALTKeyDown(nFlag);
143 } 143 }
OLDNEW
« no previous file with comments | « core/fxge/win32/fx_win32_device.cpp ('k') | fpdfsdk/formfiller/cba_fontmap.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698