Remove CFWL_WidgetMgr::GetOwnerWidget()
It always returns nullptr.
Change-Id: Icee46a77e66e7f622e78c004b9da2be89573795f
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/72771
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
diff --git a/xfa/fwl/cfwl_combolist.cpp b/xfa/fwl/cfwl_combolist.cpp
index 745ebb4..e78977b 100644
--- a/xfa/fwl/cfwl_combolist.cpp
+++ b/xfa/fwl/cfwl_combolist.cpp
@@ -64,10 +64,8 @@
}
CFX_PointF CFWL_ComboList::ClientToOuter(const CFX_PointF& point) {
- CFX_PointF ret = point + CFX_PointF(GetProperties()->m_WidgetRect.left,
- GetProperties()->m_WidgetRect.top);
- CFWL_Widget* pOwner = GetOwner();
- return pOwner ? pOwner->TransformTo(GetOuter(), ret) : ret;
+ return point + CFX_PointF(GetProperties()->m_WidgetRect.left,
+ GetProperties()->m_WidgetRect.top);
}
void CFWL_ComboList::OnProcessMessage(CFWL_Message* pMessage) {
diff --git a/xfa/fwl/cfwl_widget.h b/xfa/fwl/cfwl_widget.h
index 054c7b1..d99fbef 100644
--- a/xfa/fwl/cfwl_widget.h
+++ b/xfa/fwl/cfwl_widget.h
@@ -99,7 +99,6 @@
bool IsChild() const;
CFWL_WidgetMgr* GetWidgetMgr() const { return m_pWidgetMgr.Get(); }
- CFWL_Widget* GetOwner() { return m_pWidgetMgr->GetOwnerWidget(this); }
CFWL_Widget* GetOuter() const { return m_pOuter; }
CFWL_Widget* GetOutmost() const;
diff --git a/xfa/fwl/cfwl_widgetmgr.cpp b/xfa/fwl/cfwl_widgetmgr.cpp
index bdb343a..5ca6b9e 100644
--- a/xfa/fwl/cfwl_widgetmgr.cpp
+++ b/xfa/fwl/cfwl_widgetmgr.cpp
@@ -29,10 +29,6 @@
return pParent ? pParent->pWidget : nullptr;
}
-CFWL_Widget* CFWL_WidgetMgr::GetOwnerWidget(const CFWL_Widget* pWidget) const {
- return nullptr;
-}
-
CFWL_Widget* CFWL_WidgetMgr::GetPriorSiblingWidget(CFWL_Widget* pWidget) const {
Item* pItem = GetWidgetMgrItem(pWidget);
if (!pItem)
diff --git a/xfa/fwl/cfwl_widgetmgr.h b/xfa/fwl/cfwl_widgetmgr.h
index a932946..235dfdd 100644
--- a/xfa/fwl/cfwl_widgetmgr.h
+++ b/xfa/fwl/cfwl_widgetmgr.h
@@ -41,7 +41,6 @@
const CFX_Matrix& matrix);
CFWL_Widget* GetParentWidget(const CFWL_Widget* pWidget) const;
- CFWL_Widget* GetOwnerWidget(const CFWL_Widget* pWidget) const;
CFWL_Widget* GetNextSiblingWidget(CFWL_Widget* pWidget) const;
CFWL_Widget* GetFirstChildWidget(CFWL_Widget* pWidget) const;