Chromium Code Reviews

Unified Diff: xfa/src/fwl/src/core/fwl_appimp.cpp

Issue 1508883003: Replace more static casts in FWL (part 3) (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Index: xfa/src/fwl/src/core/fwl_appimp.cpp
diff --git a/xfa/src/fwl/src/core/fwl_appimp.cpp b/xfa/src/fwl/src/core/fwl_appimp.cpp
index 5df995c9bbd79900da76f8a2ea23b6438006d30a..2e8f7b83c34f6267118526a2fd11585f261deafa 100644
--- a/xfa/src/fwl/src/core/fwl_appimp.cpp
+++ b/xfa/src/fwl/src/core/fwl_appimp.cpp
@@ -49,7 +49,8 @@ IFWL_AdapterNative* CFWL_AppImp::GetAdapterNative() {
return m_pAdapterNative;
}
IFWL_AdapterWidgetMgr* FWL_GetAdapterWidgetMgr() {
- return ((CFWL_WidgetMgr*)FWL_GetWidgetMgr())->GetAdapterWidgetMgr();
+ return static_cast<CFWL_WidgetMgr*>(FWL_GetWidgetMgr())
+ ->GetAdapterWidgetMgr();
}
IFWL_WidgetMgr* CFWL_AppImp::GetWidgetMgr() {
return m_pWidgetMgr;
@@ -88,7 +89,8 @@ FWL_ERR FWL_SetFullScreen(IFWL_Widget* pWidget, FX_BOOL bFullScreen) {
IFWL_NoteThread* pNoteTread = pWidget->GetOwnerThread();
if (!pNoteTread)
return FWL_ERR_Succeeded;
- CFWL_NoteDriver* pNoteDriver = (CFWL_NoteDriver*)pNoteTread->GetNoteDriver();
+ CFWL_NoteDriver* pNoteDriver =
+ static_cast<CFWL_NoteDriver*>(pNoteTread->GetNoteDriver());
if (!pNoteTread)
return FWL_ERR_Succeeded;
pNoteDriver->NotifyFullScreenMode(pWidget, bFullScreen);

Powered by Google App Engine