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

Unified Diff: fpdfsdk/fsdk_baseform.cpp

Issue 1882043004: Remove implicit cast from CFX_WideString to (const wchar_t*) (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: win error #2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/fxcrt/include/fx_string.h ('k') | fpdfsdk/javascript/PublicMethods.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/fsdk_baseform.cpp
diff --git a/fpdfsdk/fsdk_baseform.cpp b/fpdfsdk/fsdk_baseform.cpp
index bfeba0e6dd802b6a7de51257f0d2f063fc29a43d..288a2fe5a3d5411cfe7f7fe4cda000336ca7955b 100644
--- a/fpdfsdk/fsdk_baseform.cpp
+++ b/fpdfsdk/fsdk_baseform.cpp
@@ -718,7 +718,7 @@ void CPDFSDK_Widget::ResetAppearance(FX_BOOL bValueChanged) {
case FIELDTYPE_COMBOBOX: {
FX_BOOL bFormated = FALSE;
CFX_WideString sValue = OnFormat(bFormated);
- ResetAppearance(bFormated ? sValue : nullptr, TRUE);
+ ResetAppearance(bFormated ? sValue.c_str() : nullptr, TRUE);
} break;
default:
ResetAppearance(nullptr, FALSE);
@@ -1546,7 +1546,7 @@ void CPDFSDK_Widget::ResetAppearance_TextField(const FX_WCHAR* sValue) {
CFX_WideString sValueTmp;
if (!sValue && GetMixXFAWidget()) {
sValueTmp = GetValue(TRUE);
- sValue = sValueTmp;
+ sValue = sValueTmp.c_str();
}
#endif // PDF_ENABLE_XFA
« no previous file with comments | « core/fxcrt/include/fx_string.h ('k') | fpdfsdk/javascript/PublicMethods.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698