From de73e09619864e92d299e7afb089bd66eee9791c Mon Sep 17 00:00:00 2001 From: Xanfre Date: Sat, 18 May 2019 17:55:38 -0500 Subject: [PATCH] Tweak reader mode values --- AngelLoader/CustomControls/RichTextBoxCustom.cs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/AngelLoader/CustomControls/RichTextBoxCustom.cs b/AngelLoader/CustomControls/RichTextBoxCustom.cs index eaf3d522e..13a8d69ee 100644 --- a/AngelLoader/CustomControls/RichTextBoxCustom.cs +++ b/AngelLoader/CustomControls/RichTextBoxCustom.cs @@ -34,7 +34,7 @@ public RichTextBoxCustom() _scrollInfo.fMask = (uint)ScrollInfoMask.SIF_ALL; ReaderModeEnabled = true; tmrAutoScroll = new Timer(); - tmrAutoScroll.Interval = AUTO_SCROLL_TICK_INTERVAL; + tmrAutoScroll.Interval = 10; tmrAutoScroll.Tick += new EventHandler(tmrAutoScroll_Tick); pbGlyph = new PictureBox(); pbGlyph.Size = new Size(26, 26); @@ -401,9 +401,6 @@ private void InterceptMousewheel(ref Message m) #region Better reader mode - const int AUTO_SCROLL_TICK_INTERVAL = 25; - const int AUTO_SCROLL_DISTANCE_MULTIPLIER = 2; - private class NativeMethods { [DllImport("comctl32.dll", SetLastError = true, EntryPoint = "#383")] @@ -500,7 +497,7 @@ private bool TranslateDispatchCallback(ref Message msg) private bool ReaderScrollCallback(ref InteropTypes.READERMODEINFO prmi, int dx, int dy) { - scrollIncrementY = dy * AUTO_SCROLL_DISTANCE_MULTIPLIER; + scrollIncrementY = dy; if (dy != 0) endOnMouseUp = true;