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

Unified Diff: xfa/fwl/lightwidget/cfwl_widget.cpp

Issue 2010923002: Add opaque "layout item" to widgets for caller's use. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Cast to FFWidget. Created 4 years, 7 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 | « xfa/fwl/lightwidget/cfwl_widget.h ('k') | xfa/fxfa/app/xfa_ffbarcode.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fwl/lightwidget/cfwl_widget.cpp
diff --git a/xfa/fwl/lightwidget/cfwl_widget.cpp b/xfa/fwl/lightwidget/cfwl_widget.cpp
index 0258c274892bcb9a9a35e75982e4eac2fe239418..239796d03ae628a94d4726c1b59142ddf3fad94f 100644
--- a/xfa/fwl/lightwidget/cfwl_widget.cpp
+++ b/xfa/fwl/lightwidget/cfwl_widget.cpp
@@ -124,9 +124,7 @@ FWL_Error CFWL_Widget::ModifyStylesEx(uint32_t dwStylesExAdded,
}
uint32_t CFWL_Widget::GetStates() {
- if (!m_pIface)
- return 0;
- return m_pIface->GetStates();
+ return m_pIface ? m_pIface->GetStates() : 0;
}
void CFWL_Widget::SetStates(uint32_t dwStates, FX_BOOL bSet) {
@@ -134,6 +132,15 @@ void CFWL_Widget::SetStates(uint32_t dwStates, FX_BOOL bSet) {
m_pIface->SetStates(dwStates, bSet);
}
+void* CFWL_Widget::GetLayoutItem() const {
+ return m_pIface ? m_pIface->GetLayoutItem() : nullptr;
+}
+
+void CFWL_Widget::SetLayoutItem(void* pItem) {
+ if (m_pIface)
+ m_pIface->SetLayoutItem(pItem);
+}
+
FWL_Error CFWL_Widget::SetPrivateData(void* module_id,
void* pData,
PD_CALLBACK_FREEDATA callback) {
« no previous file with comments | « xfa/fwl/lightwidget/cfwl_widget.h ('k') | xfa/fxfa/app/xfa_ffbarcode.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698