Tampilkan postingan dengan label android compatibility. Tampilkan semua postingan
Tampilkan postingan dengan label android compatibility. Tampilkan semua postingan

Minggu, 04 Desember 2011

Errata for "Introducing Android Development with Ice Cream Sandwich"

We recently completed a very short, very small book project: "Introducing Android Development with Ice Cream Sandwich." It's a minibook that was targeted to release with Ice Cream Sandwich. As such, the testing and development timeline was incredibly short and truncated, and devices are still not available to everyone who wants them worldwide.

Right off, we've had a reader point out one issue:

In Chapter 1, when adding the code to play an audio file from a remote URL, Android 4 (Ice Cream Sandwich) now requires and enforces the Internet permission. We've tested on previous SDK versions and, indeed, this permission was not enforced on any prior platform versions. In this case, we completely agree that it should have been -- the sample application has been using Internet data without needing to request a permission since Android 1.0-but now it needs this permission.

Luckily, the LogCat output makes this crystal clear:


12-04 15:08:15.674: D/MediaPlayer(605): Couldn't open file on client side, trying server side
12-04 15:08:15.684: W/ServiceManager(36): Permission failure: android.permission.INTERNET from uid=10044 pid=605
12-04 15:08:15.684: E/MediaPlayerService(36): Request requires android.permission.INTERNET
12-04 15:08:15.684: E/MediaPlayer(605): Unable to to create media player

The Android documentation has been updated to state, at the class level, that MediaPlayer requires the INTERNET permission when used with network based content. As it should. What isn't stated is if older SDKs will eventually be updated to enforce this permission or not. Right now, we only see this permission being enforced when running the application on API Level 14, which, right now, is less than 1% of all devices in the field. 

We apologize for any inconvenience or confusion this issue has caused. The update will also be applied to the full book, Android Wireless Application Development: Volume 1: Android Essentials: Third Edition (or, as we like to call it, AWAD3EV1). We will also update the code available on this website to reflect the permission policy change. 


Senin, 18 Juli 2011

Several New Android Updates

Android API Level 13 is
Android 3.2 is
Honeycomb
The Android team has posted several new updates in the last few days. The most obvious, which was already rolling out to consumer devices, is the Android 3.2 SDK. This is API Level 13 and is the most recent incremental update to Honeycomb. It's main new features revolve around expanded screen compatibility support. New resource qualifiers are available to developers and official support is in place for devices with screen resolutions of 1024x600 (most frequently found on 7" tablets).

The Android NDK was updated to release 6. This adds support for the x86 Application Binary Interface (ABI). Although it doesn't say as much, we're assuming this is in advance of broad availability of Android applications for Google TV devices, many of which are on Intel x86 platforms (such as the Logitech Revue, which is built around an Intel Atom processor).

The Compatibility Package has been updated to Release 3. This release marks a change from previous releases in that it now has both API Level 4 compatibility classes, several classes that are no longer exclusively for compatibility, but rather add new, useful features for developers. This includes versions of these classes for API Level 13, such that those classes behave more appropriately on the new Honeycomb release (we assume).

This has left us wondering about the future of the Compatibility Package. We've found it incredibly useful and one of the best ideas out of the Android team for adding higher level features that could be implemented on old platforms. What we're wondering is if this will become a pattern? Instead of adding a new, higher level, feature to the base API and then adding compatibility classes, will they start adding such classes directly to the Compatibility Package and now to the the base API? This would ultimately result in more efficient APIs on all SDK levels.

Either way, the Compatibility Package continues to be a very important piece of the Android picture.

Which of these updates is most interesting to you? What new opportunities do they allow for you as application developers. We love to know what you're working on!
ANDROID BOOK © 2008 Template by:
SkinCorner