Table of Contents

Class DragAdornerBehavior

Namespace
HeBianGu.Control.Adorner
Assembly
HeBianGu.Control.Adorner.dll

具有控件跟随效果的拖动样式

public class DragAdornerBehavior : Behavior<UIElement>, IAnimatable, IAttachedObject
Inheritance
DragAdornerBehavior
Implements
Derived
Inherited Members
Extension Methods

Fields

AncestorTypeProperty

public static readonly DependencyProperty AncestorTypeProperty

Field Value

DependencyProperty

DragDropEffectsProperty

public static readonly DependencyProperty DragDropEffectsProperty

Field Value

DependencyProperty

DragGroupProperty

public static readonly DependencyProperty DragGroupProperty

Field Value

DependencyProperty

IsUseProperty

public static readonly DependencyProperty IsUseProperty

Field Value

DependencyProperty

OpacityProperty

public static readonly DependencyProperty OpacityProperty

Field Value

DependencyProperty

Properties

AncestorType

public Type AncestorType { get; set; }

Property Value

Type

DragDropEffects

public DragDropEffects DragDropEffects { get; set; }

Property Value

DragDropEffects

DragGroup

判断可否放置的分组

public string DragGroup { get; set; }

Property Value

string

DropAdornerMode

public DrapAdornerMode DropAdornerMode { get; set; }

Property Value

DrapAdornerMode

Opacity

拖拽时样式透明度

public double Opacity { get; set; }

Property Value

double

RoutingStrategy

public RoutingStrategy RoutingStrategy { get; set; }

Property Value

RoutingStrategy

Methods

BeforeDoDragDrop(UIElement)

protected virtual void BeforeDoDragDrop(UIElement element)

Parameters

element UIElement

CreateDragAdorner(UIElement, Point)

protected virtual IDragAdorner CreateDragAdorner(UIElement element, Point point)

Parameters

element UIElement
point Point

Returns

IDragAdorner

DoDragDrop()

用于子类重写拖拽时放入的数据

protected virtual void DoDragDrop()

GetIsUse(DependencyObject)

public static bool GetIsUse(DependencyObject obj)

Parameters

obj DependencyObject

Returns

bool

GetMousePosition()

public static Point GetMousePosition()

Returns

Point

OnAttached()

Called after the behavior is attached to an AssociatedObject.

protected override void OnAttached()

Remarks

Override this to hook up functionality to the AssociatedObject.

OnDetaching()

Called when the behavior is being detached from its AssociatedObject, but before it has actually occurred.

protected override void OnDetaching()

Remarks

Override this to unhook functionality from the AssociatedObject.

OnIsUseChanged(DependencyObject, DependencyPropertyChangedEventArgs)

public static void OnIsUseChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)

Parameters

d DependencyObject
e DependencyPropertyChangedEventArgs

SetIsUse(DependencyObject, bool)

public static void SetIsUse(DependencyObject obj, bool value)

Parameters

obj DependencyObject
value bool