Skip to content

Commit

Permalink
Keep RichTextBox selectable after entering reader mode
Browse files Browse the repository at this point in the history
  • Loading branch information
Xanfre committed May 10, 2019
1 parent 48ff1a3 commit 4967277
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions AngelLoader/CustomControls/RichTextBoxCustom.cs
Original file line number Diff line number Diff line change
Expand Up @@ -445,14 +445,17 @@ protected override void WndProc(ref Message m)
case InteropMisc.WM_MBUTTONDOWN:
this.SetStyle(ControlStyles.Selectable, false);
DefWndProc(ref m);
this.SetStyle(ControlStyles.Selectable, true);
break;
case InteropMisc.WM_MBUTTONUP:
this.SetStyle(ControlStyles.Selectable, false);
DefWndProc(ref m);
this.SetStyle(ControlStyles.Selectable, true);
break;
case InteropMisc.WM_MBUTTONDBLCLK:
this.SetStyle(ControlStyles.Selectable, false);
DefWndProc(ref m);
this.SetStyle(ControlStyles.Selectable, true);
break;
// The below DefWndProc() call essentially "calls" this section, and this section "returns" whether
// the cursor was over a link (via LinkCursor)
Expand Down

0 comments on commit 4967277

Please sign in to comment.