diff options
author | Henrique Nakashima <hnakashima@chromium.org> | 2018-05-11 20:59:06 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-05-11 20:59:06 +0000 |
commit | d6cdd0dd2e61ecbdc652f72f84658b8502d83703 (patch) | |
tree | f0a2928f602660796b4b5b21f34b2b7fc72614de /xfa | |
parent | b222dbb346cb5b72c28fb7789613a88f64d9acb6 (diff) | |
download | pdfium-d6cdd0dd2e61ecbdc652f72f84658b8502d83703.tar.xz |
Remove CFWL_Widget::SetFocus(). It is non-op.
Change-Id: I707273c81d51124cf6ca7ba43cf1a817f3c852ea
Reviewed-on: https://pdfium-review.googlesource.com/32412
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'xfa')
-rw-r--r-- | xfa/fwl/cfwl_checkbox.cpp | 2 | ||||
-rw-r--r-- | xfa/fwl/cfwl_combobox.cpp | 2 | ||||
-rw-r--r-- | xfa/fwl/cfwl_comboedit.cpp | 1 | ||||
-rw-r--r-- | xfa/fwl/cfwl_datetimepicker.cpp | 2 | ||||
-rw-r--r-- | xfa/fwl/cfwl_edit.cpp | 6 | ||||
-rw-r--r-- | xfa/fwl/cfwl_listbox.cpp | 2 | ||||
-rw-r--r-- | xfa/fwl/cfwl_pushbutton.cpp | 3 | ||||
-rw-r--r-- | xfa/fwl/cfwl_widget.cpp | 2 | ||||
-rw-r--r-- | xfa/fwl/cfwl_widget.h | 1 |
9 files changed, 0 insertions, 21 deletions
diff --git a/xfa/fwl/cfwl_checkbox.cpp b/xfa/fwl/cfwl_checkbox.cpp index 290e59daae..d39cd534af 100644 --- a/xfa/fwl/cfwl_checkbox.cpp +++ b/xfa/fwl/cfwl_checkbox.cpp @@ -267,8 +267,6 @@ void CFWL_CheckBox::OnFocusChanged(bool bSet) { void CFWL_CheckBox::OnLButtonDown() { if (m_pProperties->m_dwStates & FWL_WGTSTATE_Disabled) return; - if ((m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0) - SetFocus(true); m_bBtnDown = true; m_pProperties->m_dwStates &= ~FWL_STATE_CKB_Hovered; diff --git a/xfa/fwl/cfwl_combobox.cpp b/xfa/fwl/cfwl_combobox.cpp index e713daca9c..f6fae087e3 100644 --- a/xfa/fwl/cfwl_combobox.cpp +++ b/xfa/fwl/cfwl_combobox.cpp @@ -258,8 +258,6 @@ void CFWL_ComboBox::ShowDropList(bool bActivate) { m_pListBox->SetWidgetRect(rtList); m_pListBox->Update(); - } else { - SetFocus(true); } if (bActivate) { diff --git a/xfa/fwl/cfwl_comboedit.cpp b/xfa/fwl/cfwl_comboedit.cpp index 4fa127745e..8bc5d25ac8 100644 --- a/xfa/fwl/cfwl_comboedit.cpp +++ b/xfa/fwl/cfwl_comboedit.cpp @@ -62,7 +62,6 @@ void CFWL_ComboEdit::OnProcessMessage(CFWL_Message* pMessage) { if ((pMsg->m_dwCmd == FWL_MouseCommand::LeftButtonDown) && ((m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0)) { SetSelected(); - m_pOuter->SetFocus(true); } break; } diff --git a/xfa/fwl/cfwl_datetimepicker.cpp b/xfa/fwl/cfwl_datetimepicker.cpp index f7492295a9..3ed2dcef19 100644 --- a/xfa/fwl/cfwl_datetimepicker.cpp +++ b/xfa/fwl/cfwl_datetimepicker.cpp @@ -432,8 +432,6 @@ void CFWL_DateTimePicker::OnFocusChanged(CFWL_Message* pMsg, bool bSet) { void CFWL_DateTimePicker::OnLButtonDown(CFWL_MessageMouse* pMsg) { if (!pMsg) return; - if ((m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0) - SetFocus(true); if (!m_rtBtn.Contains(pMsg->m_pos)) return; diff --git a/xfa/fwl/cfwl_edit.cpp b/xfa/fwl/cfwl_edit.cpp index 7872369853..7bdb818192 100644 --- a/xfa/fwl/cfwl_edit.cpp +++ b/xfa/fwl/cfwl_edit.cpp @@ -1074,9 +1074,6 @@ void CFWL_Edit::OnDrawWidget(CXFA_Graphics* pGraphics, } void CFWL_Edit::DoRButtonDown(CFWL_MessageMouse* pMsg) { - if ((m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0) - SetFocus(true); - SetCursorPosition(m_EdtEngine.GetIndexForPoint(DeviceToEngine(pMsg->m_pos))); } @@ -1115,9 +1112,6 @@ void CFWL_Edit::OnLButtonDown(CFWL_MessageMouse* pMsg) { m_bLButtonDown = true; SetGrab(true); - if ((m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0) - SetFocus(true); - bool bRepaint = false; if (m_EdtEngine.HasSelection()) { m_EdtEngine.ClearSelection(); diff --git a/xfa/fwl/cfwl_listbox.cpp b/xfa/fwl/cfwl_listbox.cpp index 0ddb65bc1a..0b0043b3cc 100644 --- a/xfa/fwl/cfwl_listbox.cpp +++ b/xfa/fwl/cfwl_listbox.cpp @@ -741,8 +741,6 @@ void CFWL_ListBox::OnFocusChanged(CFWL_Message* pMsg, bool bSet) { void CFWL_ListBox::OnLButtonDown(CFWL_MessageMouse* pMsg) { m_bLButtonDown = true; - if ((m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0) - SetFocus(true); CFWL_ListItem* pItem = GetItemAtPoint(pMsg->m_pos); if (!pItem) diff --git a/xfa/fwl/cfwl_pushbutton.cpp b/xfa/fwl/cfwl_pushbutton.cpp index a912108278..46d9876433 100644 --- a/xfa/fwl/cfwl_pushbutton.cpp +++ b/xfa/fwl/cfwl_pushbutton.cpp @@ -151,9 +151,6 @@ void CFWL_PushButton::OnFocusChanged(CFWL_Message* pMsg, bool bSet) { } void CFWL_PushButton::OnLButtonDown(CFWL_MessageMouse* pMsg) { - if ((m_pProperties->m_dwStates & FWL_WGTSTATE_Focused) == 0) - SetFocus(true); - m_bBtnDown = true; m_pProperties->m_dwStates |= FWL_STATE_PSB_Hovered; m_pProperties->m_dwStates |= FWL_STATE_PSB_Pressed; diff --git a/xfa/fwl/cfwl_widget.cpp b/xfa/fwl/cfwl_widget.cpp index f7ba040866..af46cd3d93 100644 --- a/xfa/fwl/cfwl_widget.cpp +++ b/xfa/fwl/cfwl_widget.cpp @@ -320,8 +320,6 @@ void CFWL_Widget::CalcTextRect(const WideString& wsText, pTheme->CalcTextRect(&calPart, pRect); } -void CFWL_Widget::SetFocus(bool bFocus) {} - void CFWL_Widget::SetGrab(bool bSet) { const CFWL_App* pApp = GetOwnerApp(); if (!pApp) diff --git a/xfa/fwl/cfwl_widget.h b/xfa/fwl/cfwl_widget.h index 85f9b768d3..59cdb60826 100644 --- a/xfa/fwl/cfwl_widget.h +++ b/xfa/fwl/cfwl_widget.h @@ -111,7 +111,6 @@ class CFWL_Widget : public IFWL_WidgetDelegate { CXFA_FFWidget* GetLayoutItem() const { return m_pLayoutItem; } void SetLayoutItem(CXFA_FFWidget* pItem) { m_pLayoutItem = pItem; } - void SetFocus(bool bFocus); void RepaintRect(const CFX_RectF& pRect); void Repaint(); |