Browsing articles tagged with " AIR"
Mar
10

Video: AIR 2.0 NativeProcess Example

By Joseph Labrecque  //  AIR  //  2 Comments

I’ve been looking for an opportunity to take advantage of the new flash.desktop.NativeProcess class within AIR 2.0 and was fortunate enough to have a quick project fall into my lap early this week that would serve as the perfect testing ground.

If you aren’t familiar with NativeProcess, it basically gives you the ability to interact directly with just about any process running on the host operating system. You can pass in any number of arguments into the program being invoked, and can even intercept messages being transmitted in response to your invocation.

The project basically involves building a custom interface upon the excellent HandBrake CLI for enabling server side directory polling along with custom transcoding presets complete with individual output destinations.

The following video is simply an overview of what is capable with AIR 2.0 – I hope this will be the first of many as I built this project to completion, especially as this is such an exciting (and powerful!) addition to the Flash Platform.

Feb
19

News from Mobile World Congress 2010

There is a lot of exciting news for the Flash Platform community coming out of Barcelona, Spain at the Mobile World Congress.

Firstly, Adobe has announced that Flash Player 10.1 is coming for almost all mobile operating systems including Android, the BlackBerry® platform, Symbian® OS, Palm® webOS and Windows Mobile®. Flash Player 10.1 is the first version of the Flash Player released through the cooperation of over 70 organizations including 19 of the 20 top mobile providers through the Open Screen Project.

View an excerpt from the Google Keynote:

It was also announced that AIR 2.0 would be coming to these same platforms over the next year, allowing Flash Platform developers to create applications distributable through application stores such as the Android Marketplace.

See what Nvidea has to say about Flash and AIR:

A plethora of new tablet devices were announced, all of them supporting Flash and AIR runtimes. Many of these devices allow open development, full multitasking, and extensive hardware configurations.

What perhaps may be the most important long-range announcement is that the world’s largest wireless operators (Verizon Wireless, AT&T, NTT DoCoMo, Deutsche Telekom, China Mobile, and Vodafone among them) are uniting to create “an open international applications platform” in an effort to tap demand for mobile applications. As things stand right now, the mobile world is fragmented across different operating systems, runtimes, networks, and application distribution mechanisms. This new platform would provide a single point of entry for application developers and meshes well with the open, cross-platform application distribution environment made possible by Flash Platform technologies.

Mobile is huge right now and will only gain greater momentum in the years to come. The fact that so many mobile players are collaborating on these various runtimes and initiatives should be heartening to anyone invested in the future of mobile application development.

It’s a great time to be a mobile developer, and an absolutely stellar time for Flash Platform developers!

More info:

Feb
8

Help Improve Flash 10.1 and AIR 2.0*

Okay- Adobe has a great chance to show the world how solid Flash Player and AIR engineering can be. Like any development or engineering team, they have limited resources and need help from the outside world to make these the best releases ever. Tired of “buggy” Flash and “lazy” engineers ruining your browsing experience?** Here are some things you can do to actually contribute instead of flaming Adobe:

  • Download and install Flash Player 10.1 Beta 2 and AIR 2.0 Beta 2
  • Test the new beta runtimes with your content and applications.
  • Log bugs at bugs.adobe.com. Engineering teams use your bug reports to reproduce errors and improve the runtime quality.
  • Tweet: “Improve Flash 10.1 & AIR 2.0 via Beta 2 http://bit.ly/cty7Nm READ & RT #Flash #AIR #QUALITY”

If you’re a developer, test your current applications. If you are a user, give the runtimes a spin and see if anything goes bad. We all have a great opportunity to contribute to the continued success of these two runtimes- let’s all put in some effort and make a difference!

* This is a response to Ted Patrick’s post.
** I do not believe that Flash Player is buggy or that Adobe engineers are at all lazy.

Dec
17

Adobe AIR: Preventing Users from Closing the App

By Joseph Labrecque  //  AIR  //  5 Comments

One of the really cool additions to Adobe AIR 1.5.2 was the ability to invoke preventDefault() upon a FullScreenEvent when using StageDisplayState.FULL_SCREEN_INTERACTIVE. I always had a workaround for Windows but my method would always crash the app when run on a Mac. The ability to go full screen and lock that down is essential to kiosk-type applications. This does not prevent a user from closing out the app in some other way, however.

While working on an AIR-based kiosk project this week, I was given the request to prevent COMMAND+Q from closing the application on a Mac. They really wanted this thing locked down to the point where the only way to get out of the app would be to enter some random key combination. Took a little bit of digging around to figure out how to both prevent the default closing action but still allow the app to close in the event that the correct key commands were entered. I share this here as I can see others having this same need.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?xml version="1.0" encoding="utf-8"?>
<s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009" 
					   xmlns:s="library://ns.adobe.com/flex/spark" 
					   xmlns:mx="library://ns.adobe.com/flex/mx"
					   width="400" height="400" applicationComplete="init()">
	<fx:Declarations>
		<!-- Place non-visual elements (e.g., services, value objects) here -->
	</fx:Declarations>
	<fx:Script>
		<![CDATA[
			import mx.events.CloseEvent;
			import flash.events.Event;
			import flash.display.StageDisplayState;
			import flash.events.KeyboardEvent;
			import flash.events.FullScreenEvent;
 
			private var commandEntered:Boolean;
 
			private function init():void {
				this.stage.displayState = StageDisplayState.FULL_SCREEN_INTERACTIVE;
				this.addEventListener(Event.CLOSING, appClosing, false, 0, true);
				stage.addEventListener(KeyboardEvent.KEY_DOWN, killApp, false, 0, true);
				stage.addEventListener(FullScreenEvent.FULL_SCREEN, displayStateChanged, false, 0, true);
			}
			private function displayStateChanged(e:FullScreenEvent):void {
				e.preventDefault();
			}
			private function killApp(e:KeyboardEvent):void {
				e.preventDefault();
				if(e.keyCode == 70 && e.ctrlKey && e.altKey){
					commandEntered = true;
					this.close();
				}else{
					commandEntered = false;
				}
			}
			private function appClosing(e:Event):void {
				if(!commandEntered){
					e.preventDefault();
				}
			}
		]]>
	</fx:Script>
	<s:Label text="CTRL + ALT + f" horizontalCenter="0" verticalCenter="0" fontWeight="bold" fontSize="32"/>
</s:WindowedApplication>

UPDATE: If you have a stateful application, you may want to consider the following information, as it may be disruptive in handling these events properly: http://beingwicked.com/development/flex-initialize-and-the-hassles-of-changing-state/

Dec
9

Adobe AIR 1.5.3 and Flash Player 10.0.42

Following the AIR 2 and Flash Player 10.1 betas last month, comes updates for the current platform runtimes in the form of AIR 1.5.3 and Flash Player 10.0.42.

Most important to my work is the Publisher ID changes in AIR. I’ve have the need to migrate certificates before, so have paid close attention to the changes as outlined by Oliver Goldman. Hopefully, these changes will make things more direct when having to migrate code signing certificates for our apps using a non-computed Publisher ID.

While these are minor updates to end-users, it’s important to note that Adobe does update the platform runtimes a number of times each year to address bugs and small feature enhancements. They do take good care of their platform and their users!

Adobe AIR 1.5.3 Release Notes

Adobe AIR Team blog post announcing AIR 1.5.3

About this Website

This is the website of Joseph Labrecque: Senior Multimedia Application Developer for the University of Denver and Owner of Fractured Vision Media, LLC. Joseph is an Adobe Higher Education Leader.

Adobe Higher Education Leader

Adobe Certified

Aggregated by AXNA

Follow me on Twitter!