AdornerLayout.IsAssociated Method
Gets a value indicating whether the specified model item is associated with this adorner.
Namespace: Microsoft.Windows.Design.Interaction
Assembly: Microsoft.Windows.Design.Interaction (in Microsoft.Windows.Design.Interaction.dll)
Syntax
'Declaration
Public MustOverride Function IsAssociated ( _
adorner As UIElement, _
item As ModelItem _
) As Boolean
public abstract bool IsAssociated(
UIElement adorner,
ModelItem item
)
public:
virtual bool IsAssociated(
UIElement^ adorner,
ModelItem^ item
) abstract
abstract IsAssociated :
adorner:UIElement *
item:ModelItem -> bool
public abstract function IsAssociated(
adorner : UIElement,
item : ModelItem
) : boolean
Parameters
- adorner
Type: System.Windows.UIElement
The adorner to check.
- item
Type: Microsoft.Windows.Design.Model.ModelItem
The item to compare.
Return Value
Type: System.Boolean
true if the adorner is associated with the specified model item.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | adorner or item is nulla null reference (Nothing in Visual Basic). |
Remarks
When a model item is removed from the document tree, DesignerView calls this method to check whether the adorner is using this item. If it is, DesignerView removes the adorner.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
Microsoft.Windows.Design.Interaction Namespace
PrimarySelectionAdornerProvider