From ce6eb642dbaf96fc2a9d4e97a205a0a12e7154a4 Mon Sep 17 00:00:00 2001 From: Tom Sepez Date: Thu, 4 Oct 2018 20:59:40 +0000 Subject: CPDFSDK_AnnotHandlerMgr::Annot_OnCreate() is not called. Also Annot_OnLButtonDblClk() and Annot_OnKeyUp(). Change-Id: I0a5984fc89f73f507af520c5cf5afb115b1886ce Reviewed-on: https://pdfium-review.googlesource.com/c/43490 Reviewed-by: Lei Zhang Commit-Queue: Tom Sepez --- fpdfsdk/cpdfsdk_annothandlermgr.cpp | 25 ------------------------- fpdfsdk/cpdfsdk_annothandlermgr.h | 7 ------- 2 files changed, 32 deletions(-) diff --git a/fpdfsdk/cpdfsdk_annothandlermgr.cpp b/fpdfsdk/cpdfsdk_annothandlermgr.cpp index 15ebfaacb4..0d1359512e 100644 --- a/fpdfsdk/cpdfsdk_annothandlermgr.cpp +++ b/fpdfsdk/cpdfsdk_annothandlermgr.cpp @@ -63,15 +63,6 @@ void CPDFSDK_AnnotHandlerMgr::ReleaseAnnot(CPDFSDK_Annot* pAnnot) { pAnnotHandler->ReleaseAnnot(pAnnot); } -void CPDFSDK_AnnotHandlerMgr::Annot_OnCreate(CPDFSDK_Annot* pAnnot) { - CPDF_Annot* pPDFAnnot = pAnnot->GetPDFAnnot(); - - CPDFSDK_DateTime curTime; - pPDFAnnot->GetAnnotDict()->SetNewFor( - "M", curTime.ToPDFDateTimeString(), false); - pPDFAnnot->GetAnnotDict()->SetNewFor("F", 0); -} - void CPDFSDK_AnnotHandlerMgr::Annot_OnLoad(CPDFSDK_Annot* pAnnot) { ASSERT(pAnnot); GetAnnotHandler(pAnnot)->OnLoad(pAnnot); @@ -155,16 +146,6 @@ bool CPDFSDK_AnnotHandlerMgr::Annot_OnLButtonUp( ->OnLButtonUp(pPageView, pAnnot, nFlags, point); } -bool CPDFSDK_AnnotHandlerMgr::Annot_OnLButtonDblClk( - CPDFSDK_PageView* pPageView, - CPDFSDK_Annot::ObservedPtr* pAnnot, - uint32_t nFlags, - const CFX_PointF& point) { - ASSERT(*pAnnot); - return GetAnnotHandler(pAnnot->Get()) - ->OnLButtonDblClk(pPageView, pAnnot, nFlags, point); -} - bool CPDFSDK_AnnotHandlerMgr::Annot_OnMouseMove( CPDFSDK_PageView* pPageView, CPDFSDK_Annot::ObservedPtr* pAnnot, @@ -250,12 +231,6 @@ bool CPDFSDK_AnnotHandlerMgr::Annot_OnKeyDown(CPDFSDK_Annot* pAnnot, return GetAnnotHandler(pAnnot)->OnKeyDown(pAnnot, nKeyCode, nFlag); } -bool CPDFSDK_AnnotHandlerMgr::Annot_OnKeyUp(CPDFSDK_Annot* pAnnot, - int nKeyCode, - int nFlag) { - return false; -} - bool CPDFSDK_AnnotHandlerMgr::Annot_OnSetFocus( CPDFSDK_Annot::ObservedPtr* pAnnot, uint32_t nFlag) { diff --git a/fpdfsdk/cpdfsdk_annothandlermgr.h b/fpdfsdk/cpdfsdk_annothandlermgr.h index ddf69f4e2e..799a1bee81 100644 --- a/fpdfsdk/cpdfsdk_annothandlermgr.h +++ b/fpdfsdk/cpdfsdk_annothandlermgr.h @@ -38,7 +38,6 @@ class CPDFSDK_AnnotHandlerMgr { #endif // PDF_ENABLE_XFA void ReleaseAnnot(CPDFSDK_Annot* pAnnot); - void Annot_OnCreate(CPDFSDK_Annot* pAnnot); void Annot_OnLoad(CPDFSDK_Annot* pAnnot); WideString Annot_GetText(CPDFSDK_Annot* pAnnot); @@ -71,10 +70,6 @@ class CPDFSDK_AnnotHandlerMgr { CPDFSDK_Annot::ObservedPtr* pAnnot, uint32_t nFlags, const CFX_PointF& point); - bool Annot_OnLButtonDblClk(CPDFSDK_PageView* pPageView, - CPDFSDK_Annot::ObservedPtr* pAnnot, - uint32_t nFlags, - const CFX_PointF& point); bool Annot_OnMouseMove(CPDFSDK_PageView* pPageView, CPDFSDK_Annot::ObservedPtr* pAnnot, uint32_t nFlags, @@ -94,8 +89,6 @@ class CPDFSDK_AnnotHandlerMgr { const CFX_PointF& point); bool Annot_OnChar(CPDFSDK_Annot* pAnnot, uint32_t nChar, uint32_t nFlags); bool Annot_OnKeyDown(CPDFSDK_Annot* pAnnot, int nKeyCode, int nFlag); - bool Annot_OnKeyUp(CPDFSDK_Annot* pAnnot, int nKeyCode, int nFlag); - bool Annot_OnSetFocus(CPDFSDK_Annot::ObservedPtr* pAnnot, uint32_t nFlag); bool Annot_OnKillFocus(CPDFSDK_Annot::ObservedPtr* pAnnot, uint32_t nFlag); -- cgit v1.2.3