Adobe Flex 3 Help

Scripting the HTML Container

The HTMLLoader class serves as the container for HTML content in AIR. The class provides many properties and methods, inherited from the Sprite class, for controlling the behavior and appearance of the object on the Flash display list. In addition, the class defines properties and methods for such tasks as loading and interacting with HTML content and managing history.

The HTMLHost class defines a set of default behaviors for an HTMLLoader. When you create an HTMLLoader object, no HTMLHost implementation is provided. Thus when HTML content triggers one of the default behaviors, such as changing the window location, or the window title, nothing happens. You can extend the HTMLHost class to define the behaviors desired for your application.

A default implementation of the HTMLHost is provided for HTML windows created by AIR. You can assign the default HTMLHost implementation to another HTMLLoader object by setting the htmlHost property of the object using a new HTMLHost object created with the defaultBehavior parameter set to true.

Note: In the Flex Framework, the HTMLLoader object is wrapped by the mx:HTML component. When using Flex, you should use the HTML component.

Contents