private void HandleDropInside(IDataObject dataObj, Grid grid) { Guid referenceLayer = GroupData.EndLayerGuid; LayerItem.RemoveDragEffect(grid); if (dataObj.GetDataPresent(LayerContainerDataName)) { HandleLayerDrop(dataObj, true, referenceLayer, true); } if (dataObj.GetDataPresent(LayerGroupControlDataName)) { HandleGroupControlDrop(dataObj, referenceLayer, true, true); } }
private void HandleDrop(IDataObject dataObj, Grid grid, bool above) { Guid referenceLayer = above ? GroupData.EndLayerGuid : GroupData.StartLayerGuid; LayerItem.RemoveDragEffect(grid); if (dataObj.GetDataPresent(LayerContainerDataName)) { HandleLayerDrop(dataObj, above, referenceLayer, false); } if (dataObj.GetDataPresent(LayerGroupControlDataName)) { HandleGroupControlDrop(dataObj, referenceLayer, above, false); } }
private void Grid_Drop_Center(object sender, DragEventArgs e) { HandleDropInside(e.Data, (Grid)sender); LayerItem.RemoveDragEffect(centerGrid); }
private void Grid_CenterLeave(object sender, DragEventArgs e) { LayerItem.RemoveDragEffect(centerGrid); }
private void Grid_DragLeave(object sender, DragEventArgs e) { Grid grid = (Grid)sender; LayerItem.RemoveDragEffect(grid); }