diff --git a/Shared/Scintilla.cs b/Shared/Scintilla.cs
index ab77780..f83fd1e 100644
--- a/Shared/Scintilla.cs
+++ b/Shared/Scintilla.cs
@@ -1818,7 +1818,8 @@ protected override unsafe void OnHandleCreated(EventArgs e)
// ways to solve this, but my favorite is to revoke drag and drop from the
// native Scintilla control before base.OnHandleCreated does the standard
// processing of AllowDrop.
- NativeMethods.RevokeDragDrop(Handle);
+ if (!this._ScintillaManagedDragDrop)
+ NativeMethods.RevokeDragDrop(this.Handle);
base.OnHandleCreated(e);
}
@@ -3276,6 +3277,18 @@ public unsafe void ClearRepresentation(string encodedString)
#region Properties
+ ///
+ /// Gets or sets whether Scintilla's native drag & drop should be used instead of WinForms based one.
+ ///
+ /// true if Scintilla's native drag & drop should be used; otherwise, false. The default is false.
+ [DefaultValue(false)]
+ [Category("Behaviour")]
+ [Description("Indicates whether Scintilla's native drag & drop should be used instead of WinForms based one.")]
+ public bool _ScintillaManagedDragDrop { get; set; }
+ // Underscore is used so that WinForms Designer sets it before any other
+ // property. Otherwise ApplyResources gets called on the control before
+ // the property is set, which then triggers OnHandleCreated before we
+ // have the final value.
///
/// Gets or sets the bi-directionality of the Scintilla control.