Adobe Integrated Runtime (AIR) for JavaScript Developers Pocket Reference

(nextflipdebug5) #1

68 | Chapter 4: AIR Mini-Cookbook


<td><input name="password" /></td>
</tr>
<tr>
<td colspan="2" align="right">
<input type="button" value="Sign In" />
</td>
</tr>
</table>

</body>
</html>

Creating a New Native Window


Problem


You need to display an additional window into which addi-
tional content can be loaded, and you need to be able to fine
tune how the new window appears.


Solution


TheNativeWindowclass provides the foundation for creating
and managing new windows that require a high degree of
customization and control.


Discussion


Native windows make an excellent choice for creating and
managing new windows that require a high degree of cus-
tomization. You may want the application to hide the mini-
mize/maximize buttons. You may also want to control
window z-ordering, or force a particular window to always
stay on top. TheNativeWindowclass offers control over these
aspects of a window and more.


TheNativeWindowconstructor takes two arguments; a Bool-
ean specifying whether or not the window is initially visible,
and aNativeWindowInitOptionsobject which controls aspects
of the window such as whether or not it is resizable, or even if
it has any system chrome at all. TheNativeWindowInitOptions
constructor takes no arguments:

Free download pdf