mirror of
https://github.com/Crypto-Notepad/Crypto-Notepad.git
synced 2026-03-11 08:55:25 +00:00
Fixed #26
This commit is contained in:
parent
682e1d5fa7
commit
1a7eeb1bc7
1 changed files with 10 additions and 3 deletions
|
|
@ -17,10 +17,17 @@ protected override void WndProc(ref Message m)
|
|||
int scrollLines = SystemInformation.MouseWheelScrollLines;
|
||||
for (int i = 0; i < scrollLines; i++)
|
||||
{
|
||||
if ((long)m.WParam <= 2147483647)
|
||||
SendMessage(Handle, WM_VSCROLL, (IntPtr)0, IntPtr.Zero);
|
||||
else
|
||||
try
|
||||
{
|
||||
if ((int)m.WParam >= 0)
|
||||
SendMessage(Handle, WM_VSCROLL, (IntPtr)0, IntPtr.Zero);
|
||||
else
|
||||
SendMessage(Handle, WM_VSCROLL, (IntPtr)1, IntPtr.Zero);
|
||||
}
|
||||
catch (OverflowException)
|
||||
{
|
||||
SendMessage(Handle, WM_VSCROLL, (IntPtr)1, IntPtr.Zero);
|
||||
}
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue