Recent Changes‎ > ‎

Android Studio 0.3.7 Released

posted Dec 3, 2013, 5:10 PM by Tor Norbye   [ updated Dec 3, 2013, 5:10 PM ]
We've just released Android Studio 0.3.7, with the following improvements:
  • Gradle
    • The experimental "Direct Gradle Invocation" mode is now the default. This should result in builds being about 20% faster, and the raw Gradle error output can now be found in the Gradle Console window. (You can turn off this mode in Settings > Compiler > Gradle). (The bug related to this with unsaved edits in Studio 0.3.6 has also been fixed.)
    • Improved error diagnostics. In addition to fixing error parsing for manifest merging errors, dex exceptions and multi-line javac errors, there are now import hyperlinks for resolving common import problems, such as missing platforms, missing support library repositories, or errors in local properties.
    • Improved SDK management. When opening a project which points to a specific SDK (via its file), Studio will check whether that SDK corresponds to the IDE SDK, and if not, will ask the user whether to use the Studio one or the project one. This ensures that IDE and command line builds are consistent.
    • "Add Library As..." on .jar files now works for Gradle projects; it adds in a proper dependency in the build.gradle file
    • New projects now create an empty file (with some commented out suggestions) to make it easier to tweak VM parameters for Gradle
    • Repositories for dependencies can now be edited in the Project Structure Dialog

  • Layout Editing:
    • Layout rendering sandbox: Custom views in layouts are now rendered in a sandbox such that they do not accidentally overwrite files or mistakingly execute commands if they believe they are running in a real Android environment. Note that if you download third party custom view libraries and insert references to these in your own layouts, and then view the layouts in the layout editor, the layout renderer will execute the custom view code in the IDE process with your desktop privileges. We do not promise a completely secure environment for libraries on the desktop; when adding third party libraries you should trust the source or validate that the Gradle files (which are executed at build time) and its custom views (which are executed in the layout editor) are safe. However, the layout rendering sandbox takes some initial steps to locking down access for custom views from doing thing accidentally. Thanks to Lawrence Angrave for discovering and reporting this potential danger.
    • RTL Support Improvements: When editing RelativeLayouts in the layout editor, the editor now creates RTL-aware layouts (using start/end in addition to (or instead of, depending on the minSdkVersion) left/right.
    • RTL Multi-configuration Editing: You can now edit your layouts and simultaneously see your layout rendered in an RTL context:
  • Templates
    • New templates for adding custom views, services, broadcast receivers, fragments, daydreams, etc. To invoke, right click on the target package and invoke New > Android Component.
  • Lint
    • New check looking for potential PRNG (pseudo random number generator) problems. Looks for code which may be affected by issues described in
    • New lint check which looks for calls to Context#checkCallingPermission without using the result of that call (which probably meant to call Context#enforceCallingPermission instead).
    • New lint check which looks in Gradle projects for permission for use of the mock location provider permission and makes sure these are only specified in debug manifests. This helps avoid accidentally requesting that permission in release builds.

      There's also a quickfix in Studio for migrating the permission to a debug-specific manifest, though a bug prevents it from working if the debug folder already exists (fixed for next release).
  • Bug fixes. Lots of them. Some notable ones:
    • Fix weight handling when resizing elements in a LinearLayout
    • Properly compute bounds of <include> tags in layouts
    • Fix GridLayout editing with API 19
    • Adding activities via templates no longer clobber dependencies in the build.gradle file
    • API check now properly checks nested calls
    • Detect and abort layout rendering on cyclic parent styles
    • Don't flag hex color definition characters as potential typos
    • Fix bug where on startup, layout XML files would be missing the layout editor tab
    • Make Add Translation and Render Locales use only local locales, not all locales referenced by libraries
If you are already running Android Studio, just restart it, or manually check for updates via Help > Check for Update... (on OSX, look in the Android Studio menu).  This will download and install a small patch rather than download a full IDE image.
If you need to download a full install, visit the Android Studio Canary Build 0.3.7 page. Note that if you are currently running 0.2.10 or 0.2.11, on Mac OSX, you will not be able to patch update to 0.3.4; you will need to install a fresh build due to a bug in the patch updater in those versions.

If you run into problems, be sure to check the Known Issues page which we'll update as necessary.