Android Studio 0.3.7版本主要有以下几个方面的改进: - 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 local.properties 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 gradle.properties 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 http://android-developers.blogspot.com/2013/08/some-securerandom-thoughts.html.
- 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
安装 如果你已经安装了 Android Studio, 重启或者手动的检查一下帮助菜单里有没有更新,在Android Studio菜单中点击Help > Check for Update... 这个操作将会下载一些小补丁而不是下载整个IDE。 注意:如果你正在使用Mac OSX 0.2.10 / 0.2.11版本, 那么是不能更新Mac OSX 0.3.4版补丁的,你需要重新下载安装已经更新补丁的版本。 |