Archive

Archive for the ‘adobe air’ Category

Copy/Paste keyboard shortcut doesn’t work under Mac

May 28th, 2010

In your AIR application, if you overwrite the application menu, you might find that the keyboard shortcuts (e.g. Cmd-C, V) doesn’t work under Mac. It seems the “Edit” menu in the default application is essential to these functions. So you should at least keep the “Edit” menu if you need to use your own menu.

Author: Xu Cui Categories: adobe air Tags:

use asdoc to generate documents

December 1st, 2009

First, your asdoc.exe should be in your system path

  1. Open command window, cd to your project folder. In this folder, you should find src folder
  2. Run command
    asdoc -source-path .\src -doc-sources .
  3. Then a folder called “asdoc-output” will be generated
Author: Xu Cui Categories: adobe air Tags:

Adobe AIR 2 beta is out

November 17th, 2009

Adobe AIR 2 beta is out last night (Nov 16, 2009). It includes a number of highly expected features including launching native applications. It also improves CPU/memory usages. Some sample applications include:

http://labs.adobe.com/technologies/air2/samples/

File Tile

File Tile

  1. FileTile
    Open a document with system default application (e.g. doc by Word)
    USB drive mount/unmount detection
    get icons from a file
  2. SearchCentral
    Call native applications (spotlight)
  3. Microphone
    Record voice from local microphone directly
  4. KeePIPE
    p2p application of file sharing in the same network
  5. TouchTest
    Multi-touch
Author: Xu Cui Categories: adobe air Tags:

NativeApplication.nativeApplication.exit() doesn’t exit

October 23rd, 2009

If your AIR application needs to do something (e.g. saving some settings) before quitting, you may listen to the Event.EXITING event, and then preventDefault(), then do something, and finally call NativeApplication.nativeApplication.exit() to quit. But, if you call NativeApplication.nativeApplication.exit() too quickly (e.g. call it right after preventDefault())), your application won’t exit. The solution is to wait some time (e.g. 100 ms) and call this function.

<?xml version="1.0" encoding="utf-8"?>
<mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" applicationComplete="init();">
<mx:Script>
<![CDATA[
private function init():void
{
NativeApplication.nativeApplication.addEventListener(Event.EXITING, onExiting);
}
private function onExiting(e:Event):void
{
e.preventDefault();
var t:Timer = new Timer(100);
t.addEventListener(TimerEvent.TIMER, onTimer);
t.start();

}
private function onTimer(e:TimerEvent):void
{
NativeApplication.nativeApplication.exit();
}
]]>
</mx:Script>
</mx:WindowedApplication>
Author: Xu Cui Categories: adobe air Tags:

AIR application is invisible with mx:Application

October 16th, 2009

If you use mx:WindowedApplication, you won’t have this problem. If you use mx:Application, you may find your application is not visible after launching.

Solution:  open your application description file (xxxx-app.xml) and change visible property to true.

Author: Xu Cui Categories: adobe air Tags:

Unable to build a valid certificate chain for the signer.

September 3rd, 2009

How to get a cert in the first place:

http://www.adobe.com/devnet/air/articles/signing_air_applications_print.html

If you encounter this error when signing your AIR application, do the following:

  1. Download the Thawte Code Signing CA from www.thawte.com/roots
  2. Extract the contents and find file “Thawte Code Signing CA.cer” in folder Thawte Roots\Thawte Code Signing\Code Signing CA\
  3. Open “Internet Option” from control panel, click tab Content, then Certificate, then Intermediate Certification Authority. Then click on “Import certificate” button and import “Thawte Code Signing CA.cer”
  4. Now go back to your original p12 certificate file. Double click and import your system (be sure to enter your password). Check the option “Mark this key as exportable”
  5. After importing, go to Internet Options > Content > Certificates
  6. Select your certificate and click export
  7. Next
  8. Yes, export the private key
  9. Format: PKCS, (checked) Include all certificates in the… , (checked) Enable Strong protection, (unchecked) Delete the private key …
  10. Next
  11. Enter Password for the certificate
  12. Next enter filename and export the file

It should be good.

Reference:

http://forums.adobe.com/thread/433530

Author: Xu Cui Categories: adobe air Tags:

Terrific AIR applications

August 28th, 2009

You can get all applications from Adobe Marketplace

Beautiful Design

  1. Employee Directory
    Elegant design. This application drives me to learn AIR.
  2. Adobe Media Player
    Elegant design
  3. Time 100 Desktop
    Nice design. Rotating globe, rotating pictures in 3D
  4. Times Reader
    Great text layout (how they did that?!)
  5. AOL Top 100 Videos
    Nice design, video play
  6. Spreadtweet
    Interesting idea: an excel interface but indeed a twitter client
  7. Acrobat.com for My Desktop
    Beautiful design. Buzzword is simply cool!
  8. Finetune Desktop
    Beautiful style
  9. Adobe Media Player
    Beautiful design
  10. Sam’s Interactive Reader
    Cool

Useful functions

  1. Colabolo
    Issue manager. Useful functions.
  2. Adobe Developer Connection
    Useful functions
  3. Icon Generator
    Generate icons, Very useful
  4. ActionScript 3.0 Diagram Viewer
    it would be nice if it could be more interactive
  5. Mockups For Desktop
Author: Xu Cui Categories: adobe air Tags:

“a file found in the source-path must have the same package structure”

August 12th, 2009

When you use mxmlc to compile files, you might encounter this error. You need to add source-path option:

mxmlc -source-path C:/p/y/src/ -file-specs MyClass.as -debug=true

Author: Xu Cui Categories: adobe air Tags:

What can you do with 25 lines of actionscript?

July 20th, 2009
Author: Xu Cui Categories: adobe air Tags:

Transparent windows with the mx:Window

July 6th, 2009

You set systemChrome=”none” but it still doesn’t work? You probably forget to set
showFlexChrome="false"

Author: Xu Cui Categories: adobe air Tags: