From fdc00a7042d912aafaabddae4d9c84199921ef23 Mon Sep 17 00:00:00 2001 From: Bo Xu Date: Tue, 28 Oct 2014 23:03:33 -0700 Subject: Merge XFA to PDFium master at 4dc95e7 on 10/28/2014 --- fpdfsdk/src/pdfwindow/PWL_ComboBox.cpp | 36 ++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) (limited to 'fpdfsdk/src/pdfwindow') diff --git a/fpdfsdk/src/pdfwindow/PWL_ComboBox.cpp b/fpdfsdk/src/pdfwindow/PWL_ComboBox.cpp index 01810ffd7a..744118fb9c 100644 --- a/fpdfsdk/src/pdfwindow/PWL_ComboBox.cpp +++ b/fpdfsdk/src/pdfwindow/PWL_ComboBox.cpp @@ -502,6 +502,10 @@ void CPWL_ComboBox::SetPopup(FX_BOOL bPopup) { if (m_pFillerNotify) { + FX_BOOL bExit = FALSE; + m_pFillerNotify->OnPopupPreOpen(GetAttachedData(), bExit, 0); + if (bExit) return; + FX_INT32 nWhere = 0; FX_FLOAT fPopupRet = 0.0f; FX_FLOAT fPopupMin = 0.0f; @@ -529,6 +533,10 @@ void CPWL_ComboBox::SetPopup(FX_BOOL bPopup) m_nPopupWhere = nWhere; Move(rcWindow, TRUE, TRUE); + + bExit = FALSE; + m_pFillerNotify->OnPopupPostOpen(GetAttachedData(), bExit, 0); + if (bExit) return; } } } @@ -552,6 +560,15 @@ FX_BOOL CPWL_ComboBox::OnKeyDown(FX_WORD nChar, FX_DWORD nFlag) if (m_pList->GetCurSel() > 0) { FX_BOOL bExit = FALSE; + + if (m_pFillerNotify) + { + m_pFillerNotify->OnPopupPreOpen(GetAttachedData(), bExit, nFlag); + if (bExit) return FALSE; + bExit = FALSE; + m_pFillerNotify->OnPopupPostOpen(GetAttachedData(), bExit, nFlag); + if (bExit) return FALSE; + } if (m_pList->OnKeyDownWithExit(nChar,bExit,nFlag)) { if (bExit) return FALSE; @@ -563,6 +580,15 @@ FX_BOOL CPWL_ComboBox::OnKeyDown(FX_WORD nChar, FX_DWORD nFlag) if (m_pList->GetCurSel() < m_pList->GetCount() - 1) { FX_BOOL bExit = FALSE; + + if (m_pFillerNotify) + { + m_pFillerNotify->OnPopupPreOpen(GetAttachedData(), bExit, nFlag); + if (bExit) return FALSE; + bExit = FALSE; + m_pFillerNotify->OnPopupPostOpen(GetAttachedData(), bExit, nFlag); + if (bExit) return FALSE; + } if (m_pList->OnKeyDownWithExit(nChar,bExit,nFlag)) { if (bExit) return FALSE; @@ -592,6 +618,16 @@ FX_BOOL CPWL_ComboBox::OnChar(FX_WORD nChar, FX_DWORD nFlag) } else { + if (m_pFillerNotify) + { + bExit = FALSE; + m_pFillerNotify->OnPopupPreOpen(GetAttachedData(), bExit, nFlag); + if (bExit) return FALSE; + + bExit = FALSE; + m_pFillerNotify->OnPopupPostOpen(GetAttachedData(), bExit, nFlag); + if (bExit) return FALSE; + } if (m_pList->OnCharWithExit(nChar,bExit,nFlag)) { return bExit; -- cgit v1.2.3