Remove keyboard event, focus and drawing code from IPDFSDK_AnnotHandler.
Move the affected IPDFSDK_AnnotHandler overrides to
CPDFSDK_Annot::UnsafeInputHandlers overrides instead. Then delete the
CPDFSDK_AnnotHandlerMgr pass-throughs.
Also rename many "nFlag" parameters to "nFlags" for consistency.
Change-Id: I2cd4cf1d586ebce7dfc51e874cdca4521b84cdd5
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/92370
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
diff --git a/fpdfsdk/cpdfsdk_widget.h b/fpdfsdk/cpdfsdk_widget.h
index 321f41f..94c5dd3 100644
--- a/fpdfsdk/cpdfsdk_widget.h
+++ b/fpdfsdk/cpdfsdk_widget.h
@@ -54,6 +54,9 @@
CPDF_Action GetAAction(CPDF_AAction::AActionType eAAT) override;
bool IsAppearanceValid() override;
int GetLayoutOrder() const override;
+ void OnDraw(CFX_RenderDevice* pDevice,
+ const CFX_Matrix& mtUser2Device,
+ bool bDrawAnnots) override;
bool DoHitTest(const CFX_PointF& point) override;
CFX_FloatRect GetViewBBox() override;
bool CanUndo() override;
@@ -155,6 +158,10 @@
const CFX_PointF& point) override;
bool OnRButtonUp(Mask<FWL_EVENTFLAG> nFlags,
const CFX_PointF& point) override;
+ bool OnChar(uint32_t nChar, Mask<FWL_EVENTFLAG> nFlags) override;
+ bool OnKeyDown(FWL_VKEYCODE nKeyCode, Mask<FWL_EVENTFLAG> nFlags) override;
+ bool OnSetFocus(Mask<FWL_EVENTFLAG> nFlags) override;
+ bool OnKillFocus(Mask<FWL_EVENTFLAG> nFlags) override;
CFFL_InteractiveFormFiller* GetInteractiveFormFiller();