summaryrefslogtreecommitdiff
path: root/fpdfsdk/src/formfiller
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2015-06-10 15:23:23 -0700
committerLei Zhang <thestig@chromium.org>2015-06-10 15:23:23 -0700
commit0aa0e7331b3512066df3e33d6642456a0de63de7 (patch)
treebeb51a4f1d45c4acdf4133fd3fef81fad4e35594 /fpdfsdk/src/formfiller
parent71b0378c7ce0bf8bfa54eddb2c2734729bae27f1 (diff)
downloadpdfium-0aa0e7331b3512066df3e33d6642456a0de63de7.tar.xz
Merge to XFA: Cleanup: Remove CFFL_IFormFiller::GetCommitKey() that always returns 0.
Remove callers and related code that all just pass zeros around. Also remove CFFL_IFormFiller::GetKeyDown(). R=tsepez@chromium.org Review URL: https://codereview.chromium.org/1149623012. (cherry picked from commit 35c3163d55bebea8095474181f807ddfb2f4f806) Review URL: https://codereview.chromium.org/1175083003.
Diffstat (limited to 'fpdfsdk/src/formfiller')
-rw-r--r--fpdfsdk/src/formfiller/FFL_IFormFiller.cpp63
1 files changed, 3 insertions, 60 deletions
diff --git a/fpdfsdk/src/formfiller/FFL_IFormFiller.cpp b/fpdfsdk/src/formfiller/FFL_IFormFiller.cpp
index 6f96d33da8..61fd04a0d7 100644
--- a/fpdfsdk/src/formfiller/FFL_IFormFiller.cpp
+++ b/fpdfsdk/src/formfiller/FFL_IFormFiller.cpp
@@ -871,8 +871,7 @@ void CFFL_IFormFiller::OnKeyStrokeCommit(CPDFSDK_Widget* pWidget, CPDFSDK_PageVi
fa.bModifier = m_pApp->FFI_IsCTRLKeyDown(nFlag);
fa.bShift = m_pApp->FFI_IsSHIFTKeyDown(nFlag);
fa.bWillCommit = TRUE;
- fa.nCommitKey = GetCommitKey();
- fa.bKeyDown = GetKeyDown();
+ fa.bKeyDown = TRUE;
fa.bRC = TRUE;
CFFL_FormFiller* pFormFiller = GetFormFiller(pWidget, FALSE);
@@ -911,7 +910,7 @@ void CFFL_IFormFiller::OnValidate(CPDFSDK_Widget* pWidget, CPDFSDK_PageView* pPa
PDFSDK_FieldAction fa;
fa.bModifier = m_pApp->FFI_IsCTRLKeyDown(nFlag);
fa.bShift = m_pApp->FFI_IsSHIFTKeyDown(nFlag);
- fa.bKeyDown = GetKeyDown();
+ fa.bKeyDown = TRUE;
fa.bRC = TRUE;
CFFL_FormFiller* pFormFiller = GetFormFiller(pWidget, FALSE);
@@ -968,7 +967,7 @@ void CFFL_IFormFiller::OnFormat(CPDFSDK_Widget* pWidget, CPDFSDK_PageView* pPage
ASSERT(pInterForm != NULL);
FX_BOOL bFormated = FALSE;
- CFX_WideString sValue = pInterForm->OnFormat(pWidget->GetFormField(), GetCommitKey(), bFormated);
+ CFX_WideString sValue = pInterForm->OnFormat(pWidget->GetFormField(), bFormated);
// bExit = !IsValidAnnot(m_pApp, pDocument, pDocView, pPageView, pWidget);
@@ -984,62 +983,6 @@ void CFFL_IFormFiller::OnFormat(CPDFSDK_Widget* pWidget, CPDFSDK_PageView* pPage
}
}
-// LRESULT CALLBACK CFFL_IFormFiller::FFL_WndProc(
-// int code, // hook code
-// WPARAM wParam, // virtual-key code
-// LPARAM lParam // keystroke-message information
-// )
-// {
-// if (code != HC_ACTION)
-// {
-// return CallNextHookEx (m_hookSheet, code, wParam, lParam);
-// }
-//
-// FXSYS_memcpy(&g_Msg, (void*)lParam, sizeof(MSG));
-//
-// return 0;
-// }
-
-// MSG CFFL_IFormFiller::GetLastMessage()
-// {
-// return g_Msg;
-// }
-
-int CFFL_IFormFiller::GetCommitKey()
-{
-// MSG msg = CFFL_IFormFiller::GetLastMessage();
-
- int nCommitKey = 0;
-// switch (msg.message)
-// {
-// case WM_LBUTTONDOWN:
-// case WM_LBUTTONUP:
-// nCommitKey = 1;
-// break;
-// case WM_KEYDOWN:
-// switch (msg.wParam)
-// {
-// case VK_RETURN:
-// nCommitKey = 2;
-// break;
-// case VK_TAB:
-// nCommitKey = 3;
-// break;
-// }
-// break;
-// }
-
- return nCommitKey;
-}
-
-FX_BOOL CFFL_IFormFiller::GetKeyDown()
-{
- return TRUE;
-// MSG msg = CFFL_IFormFiller::GetLastMessage();
-//
-// return msg.message == WM_KEYDOWN || msg.message == WM_CHAR;
-}
-
void CFFL_IFormFiller::OnClick(CPDFSDK_Widget* pWidget, CPDFSDK_PageView* pPageView, FX_BOOL& bReset, FX_BOOL& bExit, FX_UINT nFlag)
{
ASSERT(pWidget != NULL);