ClassVisualTreeHost
Abstraction for something that contains a visual tree root. Silverlight applications and Popups.
Definition
Namespace:ArtOfTest.WebAii.Xaml
Assembly:ArtOfTest.WebAii.dll
Syntax:
public class VisualTreeHost : IAutomationHost, ISupportSearchHost, IAnnotationHost
Inheritance: objectVisualTreeHost
Derived Classes:
Implements:
Properties
Annotator
Declaration
public virtual Annotator Annotator { get; }
Property Value
Implements
ContentWindow
Declaration
public virtual Window ContentWindow { get; }
Property Value
Implements
FriendlyName
Returns a friendly name for this host
Declaration
public virtual string FriendlyName { get; }
Property Value
Implements
Manager
Declaration
public virtual Manager Manager { get; }
Property Value
Implements
OwnerApp
The SilverlightApp containing this visual tree
ShouldDisplayAnnotation
Declaration
public bool ShouldDisplayAnnotation { get; }
Property Value
Implements
StateHashCode
Gets a unique identifier that identifies the state of this host
Declaration
public virtual string StateHashCode { get; }
Property Value
Implements
TechnologyType
VisualTreeHosts are only used for Silverlight
Declaration
public virtual TechnologyType TechnologyType { get; }
Property Value
Implements
UniqueId
A unique identifier that identifies this plugin instance. This id is updated only when the plug-in is reloaded on a postback or a browser refresh.
Declaration
public virtual string UniqueId { get; }
Property Value
Implements
VisualTree
The visual tree wrapped by this host object
Declaration
public VisualTree VisualTree { get; protected set; }
Property Value
Methods
Capture()
Return a bitmap of the host
EnsureStateIsCurrent()
Will force the VisualTree to Refresh. Identical to VisualTree.Refresh().
Declaration
public virtual void EnsureStateIsCurrent()
Implements
GetChildHosts()
Get all contained hosts.
Declaration
public virtual IAutomationHost[] GetChildHosts()
Returns
Contained Hosts
Implements
GetHostRoot()
Returns the root target element of this host. VisualTree.Root
Declaration
public virtual ITargetElement GetHostRoot()
Returns
The VisualTree.Root element
Implements
GetWindowRectangle()
Gets the rectangle of window containing this host
Declaration
public virtual Rectangle GetWindowRectangle()
Returns
Implements
LocateAllInHost(string[])
Locate all in host.
Declaration
public virtual IList<ITargetElement> LocateAllInHost(string[] expression)
Parameters
expression
string[]
The expression to use.
Returns
The list of target elements
Implements
LocateInHost(string[])
Locate an element from the root of this host using an expression.
Declaration
public virtual ITargetElement LocateInHost(string[] expression)
Parameters
expression
string[]
Returns
Implements
SetWindowFocus()
Makes the window containing this host active
Declaration
public virtual bool SetWindowFocus()
Returns
Whether we successfully set the window to active
Implements
UpdateInterHostLinks()
Silverlight hosts have no inter-host links to update
Declaration
public void UpdateInterHostLinks()
Implements
ValidateMouseLocation(Point)
Validate the location of the mouse.
Declaration
public virtual void ValidateMouseLocation(Point point)
Parameters
point
Implements