{"id":24127,"date":"2011-04-27T08:51:13","date_gmt":"2011-04-27T13:51:13","guid":{"rendered":"https:\/\/blogs.jetbrains.com\/idea\/?p=5238"},"modified":"2011-04-27T08:51:13","modified_gmt":"2011-04-27T13:51:13","slug":"mobile-air-android","status":"publish","type":"idea","link":"https:\/\/blog.jetbrains.com\/fr\/idea\/2011\/04\/mobile-air-android","title":{"rendered":"New in 10.5: Develop Mobile AIR Applications for Android"},"content":{"rendered":"<p><a href=\"http:\/\/confluence.jetbrains.net\/display\/IDEADEV\/IDEA+10.5+EAP\" target=\"_blank\" rel=\"noopener\">Latest EAP of IntelliJ IDEA 10.5<\/a> supports full cycle of <a href=\"http:\/\/help.adobe.com\/en_US\/air\/build\/WSfffb011ac560372f-5d0f4f25128cc9cd0cb-8000.html\" target=\"_blank\" rel=\"noopener\">Mobile AIR applications<\/a> development: write code, compile, package, install, run and debug on emulator or Android device! Let&#8217;s look at common development workflow.<!--more--><\/p>\n<h3>Prerequisites<\/h3>\n<ul>\n<li>Prepare your computer and Android 2.2+ device for development. <a href=\"http:\/\/www.adobe.com\/go\/fb_device_help\" target=\"_blank\" rel=\"noopener\">Enable USB debugging<\/a> on the device. Windows users probably need to install a USB driver (included in AIR SDK 2.6) and disable firewall (Vista, Windows 7) or open ports 7 and 7936 (XP).<\/li>\n<\/ul>\n<ul>\n<li><a href=\"http:\/\/opensource.adobe.com\/wiki\/display\/flexsdk\/Download+Flex+4.5\" target=\"_blank\" rel=\"noopener\">Download Flex SDK 4.5<\/a> and extract it to any folder on your computer. Alternatively if you already have Flash Builder 4.5 installed you can use SDK included in its installation.<\/li>\n<\/ul>\n<p><strong>Note:<\/strong> Pre-release versions of Flex SDK 4.5 are not supported. Use Flex SDK 4.5.0.20967.<\/p>\n<h3>Project Setup<\/h3>\n<p>Basically, all you need to create AIR mobile project in IntelliJ IDEA is to create a module of &#8216;ActionScript\/Flash\/Flex&#8217; type that uses SDK of &#8216;AIR Mobile&#8217; type. Just go through simple steps using <strong>File | New Project<\/strong> wizard. When doing it first time you need to click [&#8230;] button and add AIR Mobile SDK pointing to the Flex SDK 4.5 installation.<\/p>\n<p><a href=\"http:\/\/blogs.jetbrains.com\/idea\/wp-content\/uploads\/2011\/05\/wizard2.png\" target=\"_blank\" rel=\"noopener\"><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-5515\" title=\"wizard2\" src=\"http:\/\/blogs.jetbrains.com\/idea\/wp-content\/uploads\/2011\/05\/wizard2.png\" alt=\"\" width=\"682\" height=\"286\" \/><\/a><\/p>\n<p>As soon as a project is created it is recommended to configure default run configurations for the project. Click <strong>Run | Edit Configurations<\/strong>, expand \u2018Defaults\u2019 node and select \u2018AIR Mobile\u2019 run configuration. For example, if by default you are going to debug applications on Android device over USB you should set options in the same way as on the following screenshot.<\/p>\n<p><a href=\"http:\/\/blogs.jetbrains.com\/idea\/wp-content\/uploads\/2011\/05\/default_run_config2.png\" target=\"_blank\" rel=\"noopener\"><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-5517\" title=\"default_run_config2\" src=\"http:\/\/blogs.jetbrains.com\/idea\/wp-content\/uploads\/2011\/05\/default_run_config2.png\" alt=\"\" width=\"675\" height=\"328\" \/><\/a><\/p>\n<p>Now write some code, connect your device to the computer and launch the application.<br \/>\n<a href=\"http:\/\/blogs.jetbrains.com\/idea\/wp-content\/uploads\/2011\/05\/start_debug2.png\" target=\"_blank\" rel=\"noopener\"><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-full wp-image-5382\" title=\"start_debug2\" src=\"http:\/\/blogs.jetbrains.com\/idea\/wp-content\/uploads\/2011\/05\/start_debug2.png\" alt=\"\" width=\"500\" height=\"163\" \/><\/a><\/p>\n<p>In a few seconds the application will start on the device!<\/p>\n<p>If you need to use custom AIR application descriptor file &#8211; generate it using <strong>Tools | Flex | Generate AIR Application Descriptor<\/strong> action and then update it in a way you need. Create run configuration based on your descriptor file (in opposite to the example above where &#8216;MobileApp2&#8217; run configuration is based on application main class and descriptor file is generated by on the fly).<\/p>\n<p>To package native <strong>Android application<\/strong> as well as <strong>iOS application<\/strong> use <strong>Tools | Flex | Package Mobile AIR Application<\/strong>.<\/p>\n<p>Your feedback is always welcome in our <a href=\"http:\/\/devnet.jetbrains.net\/community\/idea\/ideacommunity\" target=\"_blank\" rel=\"noopener\">forum<\/a> and <a href=\"http:\/\/youtrack.jetbrains.net\" target=\"_blank\" rel=\"noopener\">issue tracker<\/a>!<\/p>\n","protected":false},"author":49,"featured_media":0,"comment_status":"open","ping_status":"closed","template":"","categories":[808],"tags":[2902,156,2957,3099],"cross-post-tag":[],"acf":[],"_links":{"self":[{"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/idea\/24127"}],"collection":[{"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/idea"}],"about":[{"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/types\/idea"}],"author":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/users\/49"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/comments?post=24127"}],"version-history":[{"count":0,"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/idea\/24127\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/media?parent=24127"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/categories?post=24127"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/tags?post=24127"},{"taxonomy":"cross-post-tag","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/fr\/wp-json\/wp\/v2\/cross-post-tag?post=24127"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}