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

Side by Side Diff: xfa/fxfa/app/xfa_fffield.cpp

Issue 1857073002: Make down-conversion explicit from CFX_Widetring to CFX_WideStringC. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: String argument type Created 4 years, 8 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 | « xfa/fxfa/app/xfa_ffdocview.cpp ('k') | xfa/fxfa/app/xfa_ffimageedit.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 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 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 "xfa/fxfa/app/xfa_fffield.h" 7 #include "xfa/fxfa/app/xfa_fffield.h"
8 8
9 #include "xfa/fwl/basewidget/ifwl_edit.h" 9 #include "xfa/fwl/basewidget/ifwl_edit.h"
10 #include "xfa/fwl/core/cfwl_message.h" 10 #include "xfa/fwl/core/cfwl_message.h"
(...skipping 713 matching lines...) Expand 10 before | Expand all | Expand 10 after
724 return 1; 724 return 1;
725 } 725 }
726 IXFA_AppProvider* pAppProvider = GetApp()->GetAppProvider(); 726 IXFA_AppProvider* pAppProvider = GetApp()->GetAppProvider();
727 if (pAppProvider) { 727 if (pAppProvider) {
728 CFX_WideString wsMessage; 728 CFX_WideString wsMessage;
729 CFX_WideString wsWarning; 729 CFX_WideString wsWarning;
730 pAppProvider->LoadString(XFA_IDS_NotModifyField, wsWarning); 730 pAppProvider->LoadString(XFA_IDS_NotModifyField, wsWarning);
731 wsMessage += wsWarning; 731 wsMessage += wsWarning;
732 CFX_WideString wsTitle; 732 CFX_WideString wsTitle;
733 pAppProvider->LoadString(XFA_IDS_CalcOverride, wsTitle); 733 pAppProvider->LoadString(XFA_IDS_CalcOverride, wsTitle);
734 pAppProvider->MsgBox(wsMessage, wsTitle, XFA_MBICON_Warning, 734 pAppProvider->MsgBox(wsMessage.AsWideStringC(),
735 wsTitle.AsWideStringC(), XFA_MBICON_Warning,
735 XFA_MB_OK); 736 XFA_MB_OK);
736 } 737 }
737 } 738 }
738 return 0; 739 return 0;
739 case XFA_ATTRIBUTEENUM_Warning: { 740 case XFA_ATTRIBUTEENUM_Warning: {
740 if (version <= XFA_VERSION_204) { 741 if (version <= XFA_VERSION_204) {
741 CXFA_Script script = calc.GetScript(); 742 CXFA_Script script = calc.GetScript();
742 if (!script) { 743 if (!script) {
743 return 1; 744 return 1;
744 } 745 }
(...skipping 11 matching lines...) Expand all
756 CFX_WideString wsMessage; 757 CFX_WideString wsMessage;
757 calc.GetMessageText(wsMessage); 758 calc.GetMessageText(wsMessage);
758 if (!wsMessage.IsEmpty()) { 759 if (!wsMessage.IsEmpty()) {
759 wsMessage += L"\r\n"; 760 wsMessage += L"\r\n";
760 } 761 }
761 CFX_WideString wsWarning; 762 CFX_WideString wsWarning;
762 pAppProvider->LoadString(XFA_IDS_ModifyField, wsWarning); 763 pAppProvider->LoadString(XFA_IDS_ModifyField, wsWarning);
763 wsMessage += wsWarning; 764 wsMessage += wsWarning;
764 CFX_WideString wsTitle; 765 CFX_WideString wsTitle;
765 pAppProvider->LoadString(XFA_IDS_CalcOverride, wsTitle); 766 pAppProvider->LoadString(XFA_IDS_CalcOverride, wsTitle);
766 if (pAppProvider->MsgBox(wsMessage, wsTitle, XFA_MBICON_Warning, 767 if (pAppProvider->MsgBox(wsMessage.AsWideStringC(),
768 wsTitle.AsWideStringC(), XFA_MBICON_Warning,
767 XFA_MB_YesNo) == XFA_IDYes) { 769 XFA_MB_YesNo) == XFA_IDYes) {
768 pAcc->GetNode()->SetFlag(XFA_NODEFLAG_UserInteractive, TRUE, FALSE); 770 pAcc->GetNode()->SetFlag(XFA_NODEFLAG_UserInteractive, TRUE, FALSE);
769 return 1; 771 return 1;
770 } 772 }
771 } 773 }
772 return 0; 774 return 0;
773 } 775 }
774 case XFA_ATTRIBUTEENUM_Ignore: 776 case XFA_ATTRIBUTEENUM_Ignore:
775 return 0; 777 return 0;
776 case XFA_ATTRIBUTEENUM_Disabled: 778 case XFA_ATTRIBUTEENUM_Disabled:
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
829 break; 831 break;
830 } 832 }
831 default: {} 833 default: {}
832 } 834 }
833 return FWL_ERR_Succeeded; 835 return FWL_ERR_Succeeded;
834 } 836 }
835 FWL_ERR CXFA_FFField::OnDrawWidget(CFX_Graphics* pGraphics, 837 FWL_ERR CXFA_FFField::OnDrawWidget(CFX_Graphics* pGraphics,
836 const CFX_Matrix* pMatrix) { 838 const CFX_Matrix* pMatrix) {
837 return FWL_ERR_Succeeded; 839 return FWL_ERR_Succeeded;
838 } 840 }
OLDNEW
« no previous file with comments | « xfa/fxfa/app/xfa_ffdocview.cpp ('k') | xfa/fxfa/app/xfa_ffimageedit.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698