What is air ?. How to open the air file? How Does Flex run air files?

Source: Internet
Author: User

1. When installing Adobe AIR, it is similar to Java's JVM.
Adobe AIR allows you to run the AIR application on the desktop {
Tagshow (Event)
} "> Program, out of the limitations of the browser.
{
Tagshow (Event)
} "> Download and install {
Tagshow (Event)
} "> File http://labs.adobe.com/downloads/air.html
On the download page there is a sample application http://labs.adobe.com/technologies/air/samples/

2 install {
Tagshow (Event)
} "> Development Environment
Of course, we choose flex builder with the highest development efficiency. In addition, there is also a set of tools for command line compilation.
Http://labs.adobe.com/technologies {
Tagshow (Event)
} "> Flex/flexbuilder3/download files must be registered with Adobe.

3 Adobe AIR Introduction
Adobe & reg; air is a cross-platform runtime that can use the existing {
Tagshow (Event)
} "> Web development skills (flash, flex, HTML, JavaScript, Ajax) to create desktop rich Internet applications.
The air program runs based on Adobe AIR runtime, so the developed program operates in different ways {
Tagshow (Event)
} "> The system performance is the same, just like Java.
Air allows you to use the most familiar development environment and select the tools you are best. For example
* Flash/flex/ActionScript
* Html/JavaScript/CSS/ajax

So the air application can
* Based on flash or flex, that is, the application container is flash or Flex (SWF)
* Based on flash or flex that contains HTML or PDF, that is, the application container is flash/flex, which contains HTML or PDF
* Based on HTML, the application container is HTML, JS, and CSS.
* Based on the HTML containing flash, flex, or PDF, that is, the container is HTML and contains flash, flex, and PDF.

4. Use flex builder to create the first flex AIR application
We will create an AIR application based on the SWF file and open flex builder3. Of course, flex builder is based on Eclipse and is actually an Eclipse plug-in.
Create a project of the Flex project type. Flex has two application types: web-based running in Flash Player and Adobe AIR runtime running on desktop. {
Tagshow (Event)
} "> Select none for server technology and click Finish.
Two files are initially generated: The main mxml file and the XML program configuration file.

5. Write an AIR application
All {
Tagshow (Event)
} "> The code is included in the javaswedapplication tag, which creates a simple window.
Open the mxml file in the Code view and edit it. Add a title attribute to the javaswedapplication tag. The value is set to "Hello World !"
Add a label component to the receivwedapplication element.
After the windowedapplication starts the label, insert the style block immediately. The final code is as follows:

<? XML version = "1.0" encoding = "UTF-8"?>
<Mx: Export wedapplication xmlns: MX = "http://www.adobe.com/2006/mxml" layout = "absolute" Title = "Hello World">
<Mx: style>
Application
{
Background-image :"";
Background-color :"";
Background-Alpha: "0.5 ";
}
</MX: style>
<Mx: Label text = "Hello air" horiz verticalcenter = "0"/>
</MX: Using wedapplication>

Select Adobe AIR application to run.

6. Package applications
Package the application into an air file for release. The air file is a compressed file containing all application files. You can use the air file to install the application.
First, make sure that there are no compilation errors and the operation is normal, and then select export-Flex release version.
The export prompt will require a digital signature, create one, fill in the required information OK, successful, double-click the exported air file to install, test.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.