Highlighted

NativeApplication Class Missing in AIR 13.0

New Here ,
Jan 23, 2015

Copy link to clipboard

Copied

I'm using Flash Builder 4.7 with AIR 13.0. The only three classes I'm seeing in flash.desktop package are ClipboardTransferMode, Clipboard, ClipboardFormats.

My goal is to prevent mobile devices from sleeping during gameplay. If there's a different/better solution than the one I'm chasing then please let me know.

TOPICS
Development

Views

313

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

NativeApplication Class Missing in AIR 13.0

New Here ,
Jan 23, 2015

Copy link to clipboard

Copied

I'm using Flash Builder 4.7 with AIR 13.0. The only three classes I'm seeing in flash.desktop package are ClipboardTransferMode, Clipboard, ClipboardFormats.

My goal is to prevent mobile devices from sleeping during gameplay. If there's a different/better solution than the one I'm chasing then please let me know.

TOPICS
Development

Views

314

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jan 23, 2015 0
Engaged ,
Jan 23, 2015

Copy link to clipboard

Copied

You need to use:

NativeApplication.systemIdleMode = SystemIdleMode.KEEP_AWAKE;

NativeApplication - Adobe ActionScript® 3 (AS3 ) API Reference

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 23, 2015 0
New Here ,
Jan 23, 2015

Copy link to clipboard

Copied

Thank you for your reply. As I stated in my post I am not seeing NativeApplication or SystemIdleMode in the flash.desktop package. Also, I believe you meant NativeApplication.nativeApplication.systemIdleMode as NativeApplication is a singleton and you access the instance through the nativeAppliation static getter.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 23, 2015 0
Engaged ,
Jan 23, 2015

Copy link to clipboard

Copied

Yes, exactly, my mistake. I meant:

NativeApplication.nativeApplication.systemIdleMode = SystemIdleMode.KEEP_AWAKE;

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 23, 2015 0
New Here ,
Jan 23, 2015

Copy link to clipboard

Copied

While I appreciate the reply, you're not addressing my problem. The issue is that I'm missing those classes in the flash.desktop package.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 23, 2015 0
Engaged ,
Jan 23, 2015

Copy link to clipboard

Copied

Try to use latest AIR SDK:

Download Adobe AIR SDK

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 23, 2015 0
Engaged ,
Jan 23, 2015

Copy link to clipboard

Copied

If you look at the API documentation, those 3 classes that you listed are the only non-AIR only classes in the flash.desktop package. To me that would suggest your project is not set to AIR but is set to some Flash Player version. I'm not familiar with the FB environment, so someone else will have to provide help on changing the project environment to be an AIR project.

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/desktop/package-detail.html

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 23, 2015 0
KevinF LATEST
Explorer ,
Jan 23, 2015

Copy link to clipboard

Copied

You should not be building a new mobile app with AIR 13, it won't run on newer devices and operating systems. You'll get more features and better compatibility with AIR 16.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 23, 2015 0