private void OnTrashCanDragQueryDataValid(object sender, DropHelperEventArgs e) { if (e.EventArgs.Data.GetDataPresent("Droppy.WidgetSiteDragDropData")) { e.EventArgs.Effects = DragDropEffects.Move; } else { e.EventArgs.Effects = DragDropEffects.None; } }
private void OnTrashCanDrop(object sender, DropHelperEventArgs e) { var dragData = e.EventArgs.Data.GetData("Droppy.WidgetSiteDragDropData") as WidgetSiteDragDropData; if (dragData.Widget != null) { if (dragData.Widget.HasOwner) { dragData.Widget.Parent.Remove(dragData.Widget); } } }
private void OnTrashCanDrop( object sender, DropHelperEventArgs e ) { var dragData = e.EventArgs.Data.GetData( "Droppy.WidgetSiteDragDropData" ) as WidgetSiteDragDropData; if( dragData.Widget != null ) { if( dragData.Widget.HasOwner ) { dragData.Widget.Parent.Remove( dragData.Widget ); } } }
private void OnTrashCanDragQueryDataValid( object sender, DropHelperEventArgs e ) { if( e.EventArgs.Data.GetDataPresent( "Droppy.WidgetSiteDragDropData" ) ) { e.EventArgs.Effects = DragDropEffects.Move; } else { e.EventArgs.Effects = DragDropEffects.None; } }