AIR HTML+JavaScript app vs. hardware accelerated composing

I'm developing an HTML application for mobiles and desktops. The application is optimized for WebKit based environment. To improve a rendering speed I'm using hardware accelerated layers (something like -webkit-transform: translateZ(0); etc...).
This works great on my iOS devices (using PhoneGap aka Cordova to package a "native" app).
On Windows and OS X I'm using Adobe AIR 3.5 to package a captive runtime HTML/JavaScript based application. I have found this to be the best solution (for now) even though I have tried many others (Cordova for Windows 7 / OS X, TideSDK, ...).
The point is that the HTML rendering in Adobe AIR seems not to be hardware accelerated. Does anyone of you have experience with this? Is here any possibility to enable hardware accelerated layers in AIR HTML rendering?
Thanks a lot

Thanks a lot, actually I tried AIR SDK 3.6 yesterday and it seems it still doesn't support an acceleration. In a browser it works just fine even in fullscreen (zoomed page). It seems that the best way to achieve my goal will be using Cordova wrappers for OS X and Win Desktop. But as an AIR developer I really want to use AIR SDK So I will do some more tests..
Thanks,
Pavel

Similar Messages

  • Bug in navigateToURL? (AIR HTML/JavaScript) window name parameter not working

    Hi,
    I have to popup the default browser from a HTML/JavaScript application.
    All links on the Air page should be opened in the same tab in the same browser window that was opened by the first click on a link.
    The code I use is
    var urlString = "http://www.adobe.com";
    var request = new air.URLRequest(urlString);
    air.navigateToURL(request, "myNewWindow");
    The myNewWindow parameter does not seem to be taken into account:  a new tab is opened on every click.
    I created a new Air application in Aptana and added the following straightforward code to it:
    <html>
        <head>
            <title>navigateToURLTest</title>
            <script type="text/javascript" src="lib/air/AIRAliases.js"></script>       
        </head>
        <body>   
    <a href="http://www.google.com"
                onclick="javascript:air.navigateToURL(new air.URLRequest('http://www.adobe.com'), 'AirTestWindow');return false;">New Tab</a>
            <br />
            <a href="http://www.adobe.com"
                onclick="javascript:air.navigateToURL(new air.URLRequest('http://www.adobe.com'), 'AirTestWindow');return false;">Same Tab</a>
        </body>
    </html>
    Same problem.
    Does anyone have any idea?
    Thanks

    Is there really nobody who can answer or at least try to reproduce this? 
    It's just creating a new Air HTML/Javascript application with one link with a named window target!

  • Consuming SOAP services from AIR/HTML (JavaScript).

    Hi All.
    I am trying to consume SOAP web services from an AIR/HTML application for a research on AIR I am doing for my company, and I am having very little success.
    I am creating JavaScript clients using apache's cxf wsdl2js utility.
    When I try to use the client to call any web service I've tried, I always get an 'error 500' response.
    The web services work fine if i call them from other clients.
    Before trying cxf generated clients I googled a lot to see if there was a more native way of doing these calls from AIR, but found nothing. I don't see anything in documentation or the web about it.
    Am I the only one trying this?
    Could this be a cross-domain issue? I'm certainly hoping AIR apps don't have this issue.
    Any pointers as to how to succesfully consume SOAP services from AIR is greatly appreciated.
    Thanks!

    In Visual Basic, you can set Network Credentials like this (assuming that you first declare Public CallWebService001 As New <WebReference>):
            ' Create a new instance of CredentialCache.
            Dim mycredentialCache As Net.CredentialCache = New Net.CredentialCache()
            ' Create a new instance of NetworkCredential using the client
            ' credentials.
            Dim credentials As Net.NetworkCredential = New Net.NetworkCredential(<username>, <password>)
            ' Add the NetworkCredential to the CredentialCache.
            mycredentialCache.Add(New Uri(CallWebService001.Url), "Basic", credentials)
            ' Add the CredentialCache to the proxy class credentials.
            CallWebService001.Credentials = mycredentialCache

  • Adobe Air - HTML, Javascript and Threading

    Hello,
    I am developing an application using Adobe Air - HTML and
    Javascript. What I am trying to do is to implement threading in
    Javascript. I am using implementing threading in Javascript as per
    this Neil blog.
    Click
    Here. It clearly says that this threading works only in Firefox
    2.0 and I am trying to use this in with my Adobe Air, but when I
    try to refer a function , it gives me error saying "unable to find
    it".
    I was wondering if this is the best way to go for threading
    in Adobe Air HTML application or there is some other way also.
    Thanks,
    Jaikishan

    Hi jjalan,
    The yield and generator functionality is only available in
    Firefox's javascript execution engine. When you are executing
    javascript in AIR, it is done by the webkit and squirrelfish. Take
    a look at
    http://webkit.org/blog/189/announcing-squirrelfish/
    If you can find a javascript library that works on safari /
    webkit, chances are high that it may work in AIR.
    Also, you can always do pseudo-threading via the age old
    setTimeout()

  • AIR HTML/JavaScript becomes Slower / Sleep with time

    Hi,
    This strange behavior is observed on the 2 applications I tryed.
    I've developped WikiDrop (http://wikidrop.encausse.net) a really basic TextEditor for DropBox.
    - Build with Air 2.6
    - Use HTML/JS API
    - Used on Windows Vista
    The application is launch for a long time waiting on a given computer.
    Strange Behaviors:
    - After couple of hours, displaying the main window seems to "wake up" webkit like if it was sleeping. It hang a little bit, or si slow.
    - When editig few lines of text the TextArea seems to be "slow" it's not fluid like it could be on Chrome.
    => I do not setup complexe event handler.
    => I do not have listener or keystroke on TextArea.
    Question:
    - Is there known memory leaks with HTML/JS API ?
    - Is there a Sleep/WakeUp mechanism on Adobe AIR ?
    - Is there setup/parameters to improve performances ?
    - Is there known issues about TextArea ? And workaround ?
    - May be conflicting application ? (I know Vista is bad)
    I've seens on this forum question about edition on large text file or many images but my use is really basic: only few lines of text. I got the same kind of issues with a little chat application. Text type in textarea for chat was sooo slow.
    Best Regards,
    Jp

    Hi,
    Thank you for reporting this. The internal bug number for the issue is #2740755. The issue is currently under review and will be investigated by one of AIR team members.
    Regards,
    Catalin

  • Can I run an html/javascript AIR app on Android or iOS?

    Is it possible to compile an already-existing HTML/javascript app to install/run it on any mobile OS (Android or iOS, in particular)? I haven't found anything that says it's possible, only instructions for doing it with a Flash/Flex based AIR app.
    I have a large html/javascript app, with a lot of value put into it, and my client would like to be able to package it for use on tablets. Ideally, I'd like to be able to not only have it run there, but also be able to "hide" the html/js code from prying eyes, if there's a way to do that.
    Thanks much in advance... I've done considerable research trying to get an answer to these questions.
    - Jack

    Hi Ross,
    the certificate used for APK files is a self-signed one so at this point, no need to use Google Console yet.
    See http://helpx.adobe.com/digital-publishing-suite/kb/publishing-process-android-amazon-mobil e.html (Create a certificate file using Keytool)
    Testing is only a matter of installing the APK file on the device where you should be able to test.
    The Android developer account will be useful for testing if you have in-app purchases matching 'retail' folios.

  • How to Set cookie in AIR with HTML/Javascript

    Can someone explain or post example code as to how I can go
    about setting a cookie in AIR using HTML and Javascript?
    I have an AIR app that requires the user to login on a form
    that lives in a non-applicationSandbox. I know how to
    create/modified/delete cookies using JS and a web browser, but the
    same code returns a cookie with a null value. I'm sure I'm just
    missing one line/word of code to make this happen.
    The stripped down basics of setting and reading a cookie
    using Javascript:
    document.cookie("myCookie = yummy");
    var taste = document.cookie;
    What am I doing wrong?

    quote:
    Originally posted by:
    anirudhs
    > So if I want to use cookies in AIR html/javascript the
    end user will need to have http access, whether it be from a public
    or private server?
    Yes.
    Though I am curious to why you are using cookies to store
    state on the client? This is AIR and you have access to the
    filesystem, local SQLite DB, encrypted local store, etc.
    Thanks for your previous answer anirudhs. Finally got a
    cookie thru Air! :P
    Some scenario's do require login via cookies for our webapps
    (in my case, chat w/ nicks which also logs users by serverside js +
    php, thereby allowing the same access method for web-browser login
    to the same chat rooms). It might be a bit of a stretch for some of
    us to attempt to code filesystem/SQlite/localStore updater for our
    web-users via js + php, although I know we could perhaps embed a
    hidden flash to do the localStore, and pass data back and forth
    from js, but that's lot of extra lifting, whereas browser cookies
    are naturally designed for such logins.
    I'm confused by the safari wording thou.. does the webkit
    security model in Air only work via user activated http (ie.
    clicking links), or is there some way Air can initiate an http
    connection (say using loader) to set or get cookies? It seems a
    pain to need to force the Air user to click and open a dead link
    just to activate a cookie session, even if it's only to a hidden
    frame.

  • AIR apps developed using HTML+Javascript

    Hi…
    I am working on Adobe AIR.
    And now I have 3 options to develop AIR applications 1)Flex
    2) Flash 3) HTML+javascript.
    But can you please explain me when do I exactly use Flex Or
    HTML+JS Or Flash.
    One of the reason I know is Flex used for Rich UI
    applications
    Is there any list of requirements for which one of the 3
    option is most suitable to use.
    And I have some more questions.
    1) Can AIR applications(developed using HTML+Js) invoke a web
    service running on a different server
    2) Can AIR application(developed using HTML+Js) detect the
    connectivity of USB drive (I have developed 1 application that can
    detect the Network connectivity and periodically reports the status
    I want the same in case of USB(plug & play) connectivity)
    3) I have one AIR application that has one HTML form on click
    of button I am posting the form Data to Java Servlet using
    “air.sendToURL()” as shown
    <script src="AIRAliases.js" />
    <script>
    function sendURL()
    var url = "
    http://localhost:8080/InvokingServlet/Registration";
    var variables = new air.URLVariables();
    variables.username = document.f1.username.value;
    variables.password = document.f1.password.value;
    var request = new air.URLRequest(url);
    request.data = variables;
    air.sendToURL(request);
    alert("Data has been added to Remote DB...");
    </script>
    The data goes to Servlet and then Servlet thru Jdbc
    Connectivity adds the data to database “MySQL” database
    named “user”
    If I read the data from database and print in Servlet it
    displays that to “tomcat server window(log)” But I want
    the data from Servlet to send back to HTML page where I can display
    it on the same HTML page where user entered his details. So even if
    I put the result into some Scope like session or request, but Can I
    read that it in HTML+Javascript page .
    [email protected]

    quote:
    Originally posted by:
    pravinpatil23
    But can you please explain me when do I exactly use Flex Or
    HTML+JS Or Flash.
    This question gets asked about once a week. You
    can find my latest answer
    here
    and a little searching will dig up more opinions.
    quote:
    Can AIR applications(developed using HTML+Js) invoke a web
    service running on a different server
    An AIR application isn't hosted on a server, so all web
    servers are "foreign" to your AIR application. An AIR app does get
    downloaded from a server, most of the time, but it doesn't maintain
    some kind of special connection to that server.
    Because of this, there are no cross-domain restrictions in
    AIR like you have in a regular web browser.
    quote:
    Can AIR application(developed using HTML+Js) detect the
    connectivity of USB drive
    AIR does not allow low-level system access, and has very
    little in the way of platform-specific capabilities. So, you'd have
    to use a high-level, platform-agnostic way of checking for the
    drive, such as by looking around to see what files are available.
    Things like USB insert notifications are way outside the scope of
    AIR.
    quote:
    I want the data from Servlet to send back to HTML page where
    I can display it on the same HTML page where user entered his
    details.
    That question isn't on-topic here. Ask on a forum dealing
    with JSP servlets.

  • How to enable hardware acceleration in desktop Adobe AIR app

    Hello,
    As the author of this post How do I enable hardware acceleration in an air exe? , I am trying to enable hardware acceleration inside my AIR application
    If the user has disabled hardware acceleration in his flash player's settings, context3d.driverInfo will say "Hw_disabled=userDisabled"
    His only way to re-enable it is to open Internet Explorer or Firefox and right click on a flash content, then check "Enable hardware acceleration"
    I (we) would like to be allowed to re-enable it directly inside the AIR app (via actionscript code) and not telling the user to open a browser and check some random checkboxes (cause you know it's not very user-friendly...)
    A bug has been opened here Bug#3843535 - Disabling Hardware Acceleration in IE flash plugin disables it in AIR EXEs and is marked as fixed but nothing is fixed : there's still no way to enable hardware acceleration in desktop AIR application
    Thanks

    Hello,
    I pushed to get this bug fixed and was under the impression that we addressed this back in v16.  Can you share a sample app so I can have our team take a look?
    Thanks,
    Chris

  • Convert HTML/javascript AIR app to flex-based AIR app?

    Hi all,
    I've already built an AIR app using HTML/javascript that I
    would like to monetize.
    I would like to use O2app's E-Commerce framework, which right
    now only supports Flex-created AIR apps.
    My question: Is there a simple way to "convert" an
    HTML/javascript AIR app to Flex 3 format? I'd rather not have to
    rebuild the app from scratch in Flex 3 if I don't have to. :)
    Thanks,
    Al

    Hi,
    There's no simple way to convert an HTML AIR app to flex.
    But it is possible to create HTML Root windows from a Flex
    AIR App. By root window, I mean the same kind of window that is
    launched when you launch an HTML AIR App.
    For more info, look at the HTMLLoader.createRootWindow()
    call. (This will be available from a Flex AIR app as well)

  • Link in Adobe AIR JavaScript app is incorrectly opening the app in the default browser

    I have a couple of links in my Adobe AIR JavaScript app that are part of the app's UI, which when clicked are causing the app to be loaded into a new tab in my default browser.
    This is only happening with two links (Save and Cancel on a form), and not all links in my UI.  The two links that are having the issue are defined in an external HTML file that I load a runtime and connect to the DOM.  The links that are defined in the main HTML file that is loaded when the app starts up do not have this problem.
    Here is how I am loading the template and plugging it into the DOM
    var win = document.createElement("div");
    var f = air.File.applicationDirectory.resolvePath("lib/partials/edit_form.html");
    var fs = new air.FileStream();
    fs.open(f, air.FileMode.READ);
    var content = fs.readUTFBytes(fs.bytesAvailable);
    fs.close();
    var template = new Template(content);
    win.innerHTML = template.evaluate(data);
    document.body.insertBefore(win, document.body.firstChild);
    The links themselves are coded like this:
    <a href="#" id="save_button" onclick="return false;"></a>
    <a href="#" id="cancel_button" onclick="return false;"></a>
    I am using the Prototype JS library to observe the 'click' event for each of these links like so:
    $('save_button').observe('click', onSave);
    $('save_button').observe('click', onCancel);
    This app shows content created by users, which can contain links to external web sites.  To get the external links to open in the browser (as opposed to inside my Adobe AIR window), I am doing the following in a script tag in the head of my main HTML file:
    window.htmlLoader.navigateInSystemBrowser = true
    I've found that if I set window.htmlLoader.navigateInSystemBrowser = false, then the issue with the Save and Cancel links described above goes away.  However, I need to have window.htmlLoader.navigateInSystemBrowser = true so that external links in the user content open up in the browser, not in Adobe AIR.
    Another piece of evidence is that the Save and Cancel links only incorrectly open a browser the first time you click on them after launching the app.  Subsequent clicks work fine and do not have the issue.
    Any ideas on why the links that are plugged into the DOM after app start up have this issue, and only the first time you click on them?

    Not sure where this comes from, but I suspect it has something to do with the security restrictions that AIR has in place, related to dynamic JS evaluation after the document is loaded.
    Make sure you read http://help.adobe.com/en_US/air/html/dev/WS5b3ccc516d4fbf351e63e3d118666ade46-7f0e.html#WS 5b3ccc516d4fbf351e63e3d118666ade46-7ef8
    For example, I've spotted the two onclick="return false;" you have in your code. The evaluation of the onclick attribute after the page loaded event would fail in AIR.

  • How can I run a .bat file from an html/javascript adobe air installation package?

    I write an html/javascript code which works completely true
    but when I made the installation package by air-sdk
    it dosent work properly
    my code is:
    <html>
    <head>
        <title>Hello World</title>
              <script type="text/javascript">
            function appLoad() {
                air.trace("Hello World");
        </script>
    </head>
    <body onLoad="appLoad()">
        <h1>Hello World</h1>
              <br />
    <button onclick="window.open('file:///C:/Windows/notepad.exe')"> Launch notepad </button>
    <button onclick="window.open('file:///D:/opennotepad.bat')"> Launch batnote </button>
    </body>
    </html>
    Chapter 5: Creating your first HTML-based AIR application with the AIR SDK

    Seems to be security violation. You can't execute bat or cmd

  • How to create and use Data Vault with HTML/JavaScript (SAPUI5) for Mobile Apps?

    Hello,
    I am creating a demo Enterprise Mobile App, for cross platform and I want to use the Data Vault.
    I am not able to figure out how to implement the Data Vault with HTML/JavaScript i.e. SAPUI5 for cross platform mobile apps I have a tutorial, but it is for Android based apps. Where as I want it for iOS as well. I guess, in this case, implementing the Data Vault using SAPUI5 over HTML and JavaScript would be  better.
    If anyone has any links or sample code to implement Data vault in HTML/JavaScript (SAPUI5) or specific for iOS apps, it would be great.
    Thank you.

    Hi,
    This is the "SAP Mobile Documents" community, so this seems to be the wrong place for asking your question related to Data Vault / SAPUI5.
    Maybe you should post your question here: http://scn.sap.com/community/developer-center/front-end.
    best regards,
    Ingo

  • No 'air' variable in javascript app

    Hi all,
    I'm following the HTML/Ajax developer docs, and i'm getting
    this:
    TypeError: Undefined value
    When I refer to the variable "air" in javascript. Instead, I
    have to use "runtime" which took me ages to work out because
    there's no mention of it in the docs.
    Am I right in thinking that all the docs are out of date? Are
    there any proper 1.0 docs? I'm using AIR 1.0, in HTML and
    javascript on OS X 10.5 Leopard.
    Thanks!

    Using the "air" variable requires first including
    AIRAliases.js, which is in the SDK. Both "runtime" and AIRAliases
    are documented at
    http://livedocs.adobe.com/air/1/devappshtml/help.html?content=ProgrammingHTMLAndJavaScript _05.html.
    Oliver Goldman | Adobe AIR Engineering

  • How do I enable hardware acceleration in an air exe?

    I have a Stage3d game compiled as a windows bundle (exe) using adt -target bundle. Users download it from Steam and have no idea it's even running Adobe AIR.
    The problem is that if the user has manually disabled hardware acceleration in Firefox, it will also be disabled in my game. In these cases, context3d.driverInfo will say "Hw_disabled=userDisabled". If they open Firefox, right-click on a flash animation, open the security settings box and check "enable hardware acceleration", it will start working on my Adobe AIR game too. (note this isn't on all systems - I can't recreate the problem myself)
    I would love to pop open the display tab of the security panel for them right in my game:
    Security.showSettings(Security.DISPLAY);
    But that command doesn't work in AIR, it only works in browser plugins.
    Explaining to users how to enable hardware acceleration in FF, IE, Safari etc seems like a terrible, confusing solution.
    Any better ideas?
    (also, I think this might be a bug? can anyone point me to documentation saying firefox & air should share settings like this? I went to report it but the bug tracker's down as usual: http://bugs.adobe.com/flex/)

    I found the correct/new link for the bugbase: https://bugbase.adobe.com
    and posted this issue as bug 3843535:
    https://bugbase.adobe.com/index.cfm?event=bug&id=3843535
    It seems to be an unfortunately common problem which I would love to find a workaround for if anyone has any ideas. This would be easier if I could recreate it myself...

Maybe you are looking for