Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1170)

Unified Diff: xfa/fwl/core/ifwl_caret.cpp

Issue 2467993003: Merge delegates into IFWL_* classes. (Closed)
Patch Set: Add const version Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « xfa/fwl/core/ifwl_caret.h ('k') | xfa/fwl/core/ifwl_checkbox.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fwl/core/ifwl_caret.cpp
diff --git a/xfa/fwl/core/ifwl_caret.cpp b/xfa/fwl/core/ifwl_caret.cpp
index 2dd1866642fbc819e05c3a970603dffcb26dda3d..94b56e8cf9b23fdc6fe50234f8a9a1a7c67e5df2 100644
--- a/xfa/fwl/core/ifwl_caret.cpp
+++ b/xfa/fwl/core/ifwl_caret.cpp
@@ -22,7 +22,6 @@ IFWL_Caret::IFWL_Caret(const IFWL_App* app,
m_dwElapse(400),
m_bSetColor(FALSE) {
SetStates(FWL_STATE_CAT_HightLight);
- SetDelegate(pdfium::MakeUnique<CFWL_CaretImpDelegate>(this));
}
IFWL_Caret::~IFWL_Caret() {
@@ -99,6 +98,13 @@ void IFWL_Caret::DrawCaretBK(CFX_Graphics* pGraphics,
pTheme->DrawBackground(&param);
}
+void IFWL_Caret::OnProcessMessage(CFWL_Message* pMessage) {}
+
+void IFWL_Caret::OnDrawWidget(CFX_Graphics* pGraphics,
+ const CFX_Matrix* pMatrix) {
+ DrawWidget(pGraphics, pMatrix);
+}
+
IFWL_Caret::Timer::Timer(IFWL_Caret* pCaret) : IFWL_Timer(pCaret) {}
void IFWL_Caret::Timer::Run(IFWL_TimerInfo* pTimerInfo) {
@@ -111,13 +117,3 @@ void IFWL_Caret::Timer::Run(IFWL_TimerInfo* pTimerInfo) {
rt.Set(0, 0, rt.width + 1, rt.height);
pCaret->Repaint(&rt);
}
-
-CFWL_CaretImpDelegate::CFWL_CaretImpDelegate(IFWL_Caret* pOwner)
- : m_pOwner(pOwner) {}
-
-void CFWL_CaretImpDelegate::OnProcessMessage(CFWL_Message* pMessage) {}
-
-void CFWL_CaretImpDelegate::OnDrawWidget(CFX_Graphics* pGraphics,
- const CFX_Matrix* pMatrix) {
- m_pOwner->DrawWidget(pGraphics, pMatrix);
-}
« no previous file with comments | « xfa/fwl/core/ifwl_caret.h ('k') | xfa/fwl/core/ifwl_checkbox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698