Пример #1
0
        DropEffects IDropTarget.DragOver(HtmlMouseEvent e)
        {
            base.DragOver(e);
            if (Feedback == FeedbackMode.None)
            {
                return(DropEffects.None);
            }
            object node = HitNode;

            if (!Observable.Equals(this.node, node))
            {
                this.node   = node;
                dropEffects = DropEffects.None;
                if (listItems != null)
                {
                    ListNode list = node as ListNode;
                    if (list != null)
                    {
                        dropEffects = ListItemsDropUtility.DropEffects(listItems, list.RootFolder);
                    }
                    else
                    {
                        FolderNode folder = node as FolderNode;
                        if (folder != null)
                        {
                            dropEffects = ListItemsDropUtility.DropEffects(listItems, folder);
                        }
                    }
                }
            }

            return(dropEffects & DropEffects.Move);
        }
        DropEffects IDropTarget.DragOver(HtmlMouseEvent e)
        {
            base.DragOver(e);
            ListItem listItem = HitItem as ListItem;

            targetFolder = listItem != null ? listItem.Folder : null;
            return(targetFolder != null?ListItemsDropUtility.DropEffects(source, targetFolder) : dropEffects);
        }
 internal ItemsOverviewDropTarget(ItemsPane itemsPane, IList <ListItem> source) : base(itemsPane.Overview)
 {
     this.itemsPane = itemsPane;
     this.source    = source;
     dropEffects    = ListItemsDropUtility.DropEffects(source, itemsPane.Data.FolderItems.ParentFolder);
 }