ClearCanvas.Ris.Client.View.WinForms.ListBoxWithDragSupport.ShouldBeginDrag(System.Windows.Forms.MouseEventArgs)

Here are the examples of the csharp api class ClearCanvas.Ris.Client.View.WinForms.ListBoxWithDragSupport.ShouldBeginDrag(System.Windows.Forms.MouseEventArgs) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

1 Example 7

1. Example

Project: ClearCanvas
Source File: ListBoxWithDragSupport.cs
protected override void OnMouseMove(MouseEventArgs e)
		{
			if (_itemIndexFromMouseDown != -1 && (e.Button & MouseButtons.Left) == MouseButtons.Left)
			{
				if (ShouldBeginDrag(e))
				{
					// Proceed with the drag and drop.  
					this.DoDragDrop(_itemIndexFromMouseDown, DragDropEffects.All);

					// reset the drag box to empty so that the event is not fired repeatedly
					_dragBoxFromMouseDown = Rectangle.Empty;
				}
			}
			else
			{
				// allow the base class to handle it only if the left mouse button was not pressed
				base.OnMouseMove(e);
			}
		}