Replace a #define in cfwl_scrollbar.cpp
-- convert a pre-existing const to constexpr
Change-Id: Ib9f3a295a132ee8225ce7aeca347a3a00c9b9cf4
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/83555
Auto-Submit: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
diff --git a/xfa/fwl/cfwl_scrollbar.cpp b/xfa/fwl/cfwl_scrollbar.cpp
index b967911..f622d766 100644
--- a/xfa/fwl/cfwl_scrollbar.cpp
+++ b/xfa/fwl/cfwl_scrollbar.cpp
@@ -19,11 +19,11 @@
#include "xfa/fwl/cfwl_themepart.h"
#include "xfa/fwl/ifwl_themeprovider.h"
-#define FWL_SCROLLBAR_Elapse 500
namespace {
-const float kMinThumbSize = 5.0f;
+constexpr int kScrollbarElapsedMsecs = 500;
+constexpr float kMinThumbSize = 5.0f;
} // namespace
@@ -339,7 +339,7 @@
if (!SendEvent()) {
m_pTimer = std::make_unique<CFX_Timer>(GetFWLApp()->GetTimerHandler(), this,
- FWL_SCROLLBAR_Elapse);
+ kScrollbarElapsedMsecs);
}
}