... development increases and your
applications grow new windows and components, you may become
interested in passing data around and ensuring that the data remains in scope.
Misunderstanding that scope ... way.
5.3.4. Creating Elements Dynamically
Using the createElement method in XUL lets you accomplish things
similar to document.write in HTML, with which you can create new
pa...
... section Section 5.5.1 .6
, later in this chapter,
demonstrates.
xpcshell is the command-line interpreter to JavaScript and XPConnect. This
shell that uses XPConnect to call and instantiate scriptable ... using the File and FileUtils interfaces is that
methods and properties on the latter are singleton and require a path
argument, while the FileUtils utilities are general purpo...
... file as a standalone window, organizing the
code into separate files and a package structure, and registering and
launching that package are the basic building blocks of all Mozilla
applications. ...
describe their contents and make it possible to register them with Mozilla. A
manifest is an RDF file (or series of RDF files) that sits within the package
and interacts with M...
... 6. Packaging and Installing Applications- P1
The previous chapters covered the basic parts of building an application.
Now that you've seen how to create an application with XUL, CSS, and ... installable, and
registrable allows others to use what you have created.
This chapter is divided into four main sections. It starts with a quick
overview of the basics of packa...
... Chapter 6. Packaging and Installing Applications- P2
6. 2.3.4. Overlaying Mozilla files into your application
In the previous ... out the XPI and its internal installation script
altogether and use a trigger script like Example 6- 13
and a regular JAR file
to download and register the new package.
Example 6- 13. Scriptless ... (Example 6- 16
) organized into such hig...
... 2 and 3 is to give your icon the same name as the
Mozilla icon (mozilla.ico) and just drop it into the tree, replacing the
existing one shown in Figure 6- 6
.
Figure 6- 6. Windows taskbar with ... Chapter 6. Packaging and Installing Applications- P3
When you have very simple installations such as when you want to ...
method and its improvement.
6. 4. Finishing Things U...
... Modularity, good
exception handing, regular expression enhancement, and number formatting
are just some features of the new JavaScript 1.5,[1]
which is based on the
ECMA- 262 standard.[2]
JavaScript ...
associated with a XUL window and the other XUL elements, but you can
see all of them if you run the example. Analyzing output like this can
familiarize you with the interfaces...
... are comfortable with how JavaScript works in the context of the
user interface layer and are familiar with some of the primary DOM methods
used to manipulate the various elements and attributes, ... to start and stop.
When the user clicks a XUL button, for instance, the button "listens" for the
click event, and may also handle that event. If the button itself does no...
... bindings file (and possibly the path to
it) as a parameter, and the id of the binding denoted with the # notation. For
the binding to take, the XBL file must contain a binding with the same ... the textbox is fabricated
and used here to avoid bugs and scope issues with the id attribute in
content. The id attribute should be used only on the <binding> and
<bindings&...
... like onclick and
onmousedown, and provide a means for trapping them within your binding
and carrying out tasks associated with them.
<handlers>
<handler event="mouseover"> ... );
</handler>
</handlers>
Each handler is contained in a <handler> tag and the event name is
placed in the event attribute minus the "on" prefix. The...