Tampilkan postingan dengan label Tools. Tampilkan semua postingan
Tampilkan postingan dengan label Tools. Tampilkan semua postingan

Kamis, 10 Desember 2015

Android Studio 2.0 Preview: Android Emulator


Posted by, Jamal Eason, Product Manager, Android




An early preview of the new Android Emulator is now available to try out. As a part of Android Studio 2.0, the latest version of the Android Emulator can help you test your app on a wide range of screens size and configurations beyond the physical Android hardware you use to test.Moreover, using the official Android emulator enables you to test with latest Android versions. Building on this foundation, the top two benefits of new Android emulator are:





  • Speed & Performance: When emulating the latest Android 6.0 release (Marshmallow), we now support Symmetric Multi-Processing and have made significant I/O improvements in both the emulator and ADB. This means you will have faster performance when you are testing your app.




  • Usability & User Interface: The new Android Emulator includes a brand new user interface to make the emulator easy to use. You no longer have to rely on command-line parameters to use the Android emulator. Common tasks and emulator features are now just a mouse click or a keyboard shortcut away.


We previewed the user interface at the Android Dev Summit. You can try it out today along with the new version of ADB for faster APK installation and file transfers to the emulator. Check out the video for a demonstration of the new Android Emulator.







Android Dev Summit 2015: Emulator Demo


We are seeking early feedback to continue to deliver the experience and features that will make you more productive.



Performance Improvements


CPU Performance



Android Studio now uses CPU acceleration on x86 emulator system images by default. Combined with new Symmetric Multi-Processor (SMP) support in Android 6.0 Marshmallow system images, the Android emulators can perform even faster than many physical Android devices. Multi-core support not only makes your apps and the emulator run faster but it provides the added advantage of speeding up common developer tasks such as installing APKs. Also, with SMP you can test apps that specifically target multi-processor Android devices.



Faster ADB



In addition to faster CPU speeds in the emulator, there are a number of under-the-hood improvements that will make the experience faster. One of the bottlenecks in the development process that we worked on is the speed of pushing data between Android Studio and your device using ADB (Android Debug Bridge). When you use Android 6.0 Marshmallow and higher system images with the new Android Emulator, you can now push files across ADB up to five times faster than a real device. This will help you if you push large APK or files during your app development cycle.




User Interface



Toolbar



The new interface exposes some of the most common emulator actions in a new toolbar and control panel instead of solely relying on command line options. For the preview, the Android Emulator toolbar enables actions, such as volume control, screen rotation, and screen-shots of the emulator window.





Window Zooming & Scaling


Now you can resize your window simply by dragging a corner. You can also zoom and scroll to get a closer look at a portion of your screen.












Left: Zooming
Right: Window Scaling



Drag & Drop


With the new emulator, you can not only drag and drop APKs for quick installation, but you can also drag and drop any file to your emulator’s internal SD card to help in testing.






Drag and Drop Files


Extended UI Controls


In the extended controls window, additional options help you validate and test features in your app. As shown below, you can initiate a range of emulator actions such as making a virtual call, sending a virtual SMS, or controlling the power level of the emulator. You can additionally send a single GPS location point to the emulator or play back a custom set of KML or GPX points as well.






Phone Controls




Battery Controls

We are continuing to add more functionality and we will keep you up to date as we add more features.



What's Next & Setup


This is just the beginning of developments on the Android Emulator, so expect more features such as support more APIs levels, and adding more sensors with future versions of Android Studio. The new emulator along with Android Studio are available today on the Android Studio canary channel and tools preview channel.



Click here for details on how to setup the preview of the new Android Emulator.


We appreciate your feedback. Connect with us, the Android Studio development team, on Google+.



Kamis, 30 Juli 2015

Get your hands on Android Studio 1.3





Posted by Jamal Eason, Product Manager, Android



Previewed earlier this summer at Google I/O, Android Studio 1.3 is now available on the stable release channel. We appreciated the early feedback from those developers on our canary and beta channels to help ship a great product.



Android Studio 1.3 is our biggest feature release for the year so far, which includes a new memory profiler, improved testing support, and full editing and debugging support for C++. Let’s take a closer look.




New Features in Android Studio 1.3




Performance & Testing Tools



  • Android Memory (HPROF) Viewer

    Android Studio now allows you to capture and analyze memory snapshots in the native Android HPROF format.





  • Allocation Tracker

    In addition to displaying a table of memory allocations that your app uses, the updated allocation tracker now includes a visual way to view the your app allocations.





  • APK Tests in Modules

    For more flexibility in app testing, you now have the option to place your code tests in a separate module and use the new test plugin (‘com.android.test’) instead of keeping your tests right next to your app code. This feature does require your app project to use the Gradle Plugin 1.3.






Code and SDK Management




  • App permission annotations

    Android Studio now has inline code annotation support to help you manage the new app permissions model in the M release of Android. Learn more about code annotations.





  • Data Binding Support

    New data brinding features allow you to create declarative layouts in order to minimize boilerplate code by binding your application logic into your layouts. Learn more about data binding.





  • SDK Auto Update & SDK Manager

    Managing Android SDK updates is now a part of the Android Studio. By default, Android Studio will now prompt you about new SDK & Tool updates. You can still adjust your preferences with the new & integrated Android SDK Manager.







  • C++ Support

    As a part of the Android 1.3 stable release, we included an Early Access Preview of the C++ editor & debugger support paired with an experimental build plugin. See the Android C++ Preview page for information on how to get started. Support for more complex projects and build configurations is in development, but let us know your feedback.






Time to Update




An important thing to remember is that an update to Android Studio does not require you to change your Android app projects. With updating, you get the latest features but still have control of which build tools and app dependency versions you want to use for your Android app.



For current developers on Android Studio, you can check for updates from the navigation menu. For new users, you can learn more about Android Studio on the product overview page or download the stable version from the Android Studio download site.



We are excited to launch this set of features in Android Studio and we are hard at work developing the next set of tools to make develop Android development easier on Android Studio. As always we welcome feedback on how we can help you. Connect with the Android developer tools team on Google+.




Jumat, 26 Juni 2015

An update on Eclipse Android Developer Tools


Posted by Jamal Eason, Product Manager, Android


Over the past few years, our team has focused on improving the development experience for building Android apps with Android Studio. Since the launch of Android Studio, we have been impressed with the excitement and positive feedback. As the official Android IDE, Android Studio gives you access to a powerful and comprehensive suite of tools to evolve your app across Android platforms, whether it's on the phone, wrist, car or TV.



To that end and to focus all of our efforts on making Android Studio better and faster, we are ending development and official support for the Android Developer Tools (ADT) in Eclipse at the end of the year. This specifically includes the Eclipse ADT plugin and Android Ant build system.




Time to Migrate


If you have not had the chance to migrate your projects to Android Studio, now is the time. To get started, download Android Studio. For many developers, migration is as simple as importing your existing Eclipse ADT projects in Android Studio with File → New→ Import Project as shown below:










For more details on the migration process, check out the migration guide. Also, to learn more about Android Studio and the underlying build system, check out this overview page.




Next Steps


Over the next few months, we are migrating the rest of the standalone performance tools (e.g. DDMS, Trace Viewer) and building in additional support for the Android NDK into Android Studio.



We are focused on Android Studio so that our team can deliver a great experience on a unified development environment. Android tools inside Eclipse will continue to live on in the open source community via the Eclipse Foundation. Check out the latest Eclipse Andmore project if you are interested in contributing or learning more.



For those of you that are new to Android Studio, we are excited for you to integrate Android Studio into your development workflow. Also, if you want to contribute to Android Studio, you can also check out the project source code. To follow all the updates on Android Studio, join our Google+ community.
















Selasa, 21 April 2015

Android Support Library 22.1

Posted by Ian Lake, Developer Advocate



You may have heard the phrase ‘the best code is no code.’ While we don’t recommend not writing any code at all, the code you do write should be adding unique value to your app rather than replicating common boilerplate code. The Android Support Library is one of the best resources for accomplishing this by taking care of the little things for you.



The latest release of the Android Support Library is no different, adding a number of extremely helpful components and changes across the Support V4, AppCompat, Leanback, RecyclerView, Palette, and Renderscript libraries. From the new AppCompatActivity and AppCompatDialog to a new guided step flow for Android TV, there’s a lot to get excited about in this release.



Support V4



The Support V4 library serves as the base of much of the Android Support Library and contains many of the classes focused on making backward compatibility much easier.



DrawableCompat now brings drawable tinting back to API 4: simply wrap your Drawable via DrawableCompat.wrap(Drawable) and setTint(), setTintList(), and setTintMode() will just work: no need to create and maintain separate drawables only to support multiple colors!



In addition, we’re making some of the internals of Palette available to all via the ColorUtils class, giving you pre-built tools to better work with colors. ColorUtils makes it easy to calculate the contrast ratio between colors, determine the minimum alpha value to maintain a minimum contrast (perfect for ensuring readable text), or convert colors to their HSL components.



Interpolators are an important part of any animation system, controlling the rate of change in an animation (say accelerating, decelerating, etc). A number of interpolators were added in Lollipop to android.R.interpolator including fast_out_linear_in, fast_out_slow_in, and linear_out_slow_in: important parts of building authentic motion. These are now available via the Support Library via the FastOutLinearInInterpolator, FastOutSlowInInterpolator, and LinearOutSlowInInterpolator classes, making it possible to use these via code for all animations. In addition to those pre-built interpolators, we’ve also created PathInterpolatorCompat, allowing you to build quadratic and cubic Bezier curves as well.



This release also moves the Space widget from the GridLayout library into Support V4, making it available without requiring a separate dependency. The Space widget is a lightweight, invisible View that can be used to create gaps between components.



AppCompat



The AppCompat Support Library started with humble, but important beginnings: a single consistent Action Bar for all API 7 and higher devices. In revision 21, it took on new responsibility: bringing material color palette, widget tinting, Toolbar support, and more to all API 7+ devices. With that, the name ActionBarActivity didn’t really cover the full scope of what it really did.



In this release, ActionBarActivity has been deprecated in favor of the new AppCompatActivity. However, this wasn’t just a rename. In fact, the internal logic of AppCompat is now available via AppCompatDelegate - a class you can include in any Activity, hook up the appropriate lifecycle methods, and get the same consistent theming, color tinting, and more without requiring you to use AppCompatActivity (although that remains the easiest way to get started).



With the help of the new AppCompatDelegate, we’ve also added support for consistent, material design dialogs via the AppCompatDialog class. If you’ve used AlertDialog before, you’ll be happy to know there is also now a Support Library version in support.v7.app.AlertDialog, giving you the same API as well as all the benefits of AppCompatDialog.



The ability to tint widgets automatically when using AppCompat is incredibly helpful in keeping strong branding and consistency throughout your app. This is done automatically when inflating layouts - replacing Button with AppCompatButton, TextView with AppCompatTextView, etc. to ensure that each could support tinting. In this release, those tint aware widgets are now publicly available, allowing you to keep tinting support even if you need to subclass one of the supported widgets.



The full list of tint aware widgets at this time is:
  • AppCompatAutoCompleteTextView

  • AppCompatButton

  • AppCompatCheckBox

  • AppCompatCheckedTextView

  • AppCompatEditText

  • AppCompatMultiAutoCompleteTextView

  • AppCompatRadioButton

  • AppCompatRatingBar

  • AppCompatSpinner

  • AppCompatTextView


Lollipop added the ability to overwrite the theme at a view by view level by using the android:theme XML attribute - incredibly useful for things such as dark action bars on light activities. Now, AppCompat allows you to use android:theme for Toolbars (deprecating the app:theme used previously) and, even better, brings android:theme support to all views on API 11+ devices.



If you’re just getting started with AppCompat, check out how easy it is to get started and bring a consistent design to all of your users:







Leanback



With the Leanback library serving as the collection of best practices for Android TV apps, we’d be remiss to not make an even better 10’ experience as part of the release with the new guided step functionality.





This set of classes and themes can be used to build a multiple step process that looks great on Android TV. It is constructed from a guidance view on the left and a list of actions on the right. Each is customizable via themes with a parent of Theme.Leanback.GuidedStep or, if even more customization is needed, through custom a GuidanceStylist and GuidedActionsStylist.



You’ll also find a large number of bug fixes, performance improvements, and an extra coat of polish throughout the library - all with the goal of making the Leanback experience even better for users and developers alike.



RecyclerView



Besides a healthy set of bug fixes, this release adds a new SortedList data structure. This collection makes it easy to maintain a sorted list of custom objects, correctly dispatching change events as the data changes through to RecyclerView.Adapter: maintaining the item added/deleted/moved/changed animations provided by RecyclerView.



In addition, SortedList also supports batching changes together, dispatching just a single set of operations to the Adapter, ensuring the best user experience when a large number of items change simultaneously.



Palette



If you’ve been using Palette to extract colors from images, you’ll be happy to know that it is now 6-8 times faster without sacrificing quality!



Palette now uses a Builder pattern for instantiation. Rather than directly calling Palette.generate(Bitmap) or their equivalents, you’ll use Palette.from(Bitmap) to retrieve a Palette.Builder. You can then optionally change the maximum number of colors to generate and set the maximum size of the image to run Palette against before calling generate() or generateAsync() to retrieve the color Swatches.



Renderscript



Renderscript gives you massive compute potential and the Support Library version makes a number of the pre-defined scripts, called script intrinsics, available to all API 8+ devices. This release improves reliability and performance across all devices with an improved detection algorithm in determining whether the native Renderscript functionality can be used - ensuring the fastest, most reliable implementation is always chosen. Two additional intrinsics are also added in this release: ScriptIntrinsicHistogram and ScriptIntrinsicResize, rounding out the collection to ten.



SDK available now!


There’s no better time to get started with the Android Support Library. You can get started developing today by downloading the Android Support Library and Android Support Repository from the Android SDK Manager.



To learn more about the Android Support Library and the APIs available to you through it, visit the Support Library section on the Android Developer site.