XamlLight.OnConnected(UIElement) Method

Definition

This method is automatically called when the XamlLight is first in use on the screen, or after being previously disconnected then used again.

This provides an opportunity to create resources such as the CompositionLight only when required.

OnDisconnected will be called when the XamlLight is no longer being used to light any UIElements or Brushes.

protected:
 virtual void OnConnected(UIElement ^ newElement) = OnConnected;
void OnConnected(UIElement const& newElement);
protected virtual void OnConnected(UIElement newElement);
function onConnected(newElement)
Protected Overridable Sub OnConnected (newElement As UIElement)

Parameters

newElement
UIElement

The UIElement that the light is attached to.

Applies to