whats new in ics

satya - Tuesday, December 06, 2011 3:01:30 PM

Resizable widgets in ics

Resizable widgets in ics

Search for: Resizable widgets in ics

satya - Friday, December 09, 2011 1:03:37 PM

Here is a quick little video on youtube how this feature is used

Here is a quick little video on youtube how this feature is used

This video demonstrates that the widgets are

scrollable
resizable

satya - Friday, December 09, 2011 1:12:24 PM

AppWidgetProviderInfo XML now has resize attribute


<appwidget-provider 
xmlns:android="http://schemas.android.com/apk/res/android"    
android:minWidth="294dp"    
android:minHeight="72dp"    
android:updatePeriodMillis="86400000"    
android:previewImage="@drawable/preview"    
android:initialLayout="@layout/example_appwidget"    
android:configure="com.example.android.ExampleAppWidgetConfigure"     
android:resizeMode="horizontal|vertical">
</appwidget-provider>

satya - Friday, December 09, 2011 1:12:53 PM

here is what resizeMode does

The resizeMode attribute specifies the rules by which a widget can be resized. You use this attribute to make homescreen widgets resizeable?horizontally, vertically, or on both axes. Users touch-hold a widget to show its resize handles, then drag the horizontal and/or vertical handles to change the size on the layout grid. Values for the resizeMode attribute include "horizontal", "vertical", and "none". To declare a widget as resizeable horizontally and vertically, supply the value "horizontal|vertical". Introduced in Android 3.1.

satya - Friday, December 09, 2011 1:21:27 PM

Image preview is new in 3.0 for widgets

Image preview is new in 3.0 for widgets

satya - Saturday, December 10, 2011 10:24:20 AM

The way you pick a widget has changed in ics

Previously you long click on the home page to navigate to your widgets. In ICS the widgets is a tab on the list of applications activity. So click on "apps" on the home page. You will see a tab then called "widgets". Again this is the emulator. On a real device there may be more variations.

satya - Saturday, December 10, 2011 11:10:13 AM

what is autoAdvacneViewId?

what is autoAdvacneViewId?

Search for: what is autoAdvacneViewId?

satya - Saturday, December 10, 2011 11:29:24 AM

The scoop on resizable widgets

Yes. you can set the resizing to none, or horizontal, or vertical or a combination there of.

However to take adavantage of this, your widget controls should be laid out such a way that they can expand and contract using their layout parameters.

There is no callback to tell you what size your widget is. The update is not triggered, at leas the documentation doesn't hint of such a fact.

satya - Saturday, December 10, 2011 12:05:31 PM

auto advance StackView

auto advance StackView

Search for: auto advance StackView

satya - Saturday, December 10, 2011 12:21:20 PM

The key to understandign auto advance is to understand the adapter view animator

The key to understandign auto advance is to understand the adapter view animator

satya - Saturday, December 10, 2011 1:12:14 PM

Scoop on preview attribute

when you set this, this is the icon you see in the widget list for you to pick. If you don't set this you will see your widge applications icon that is set in the manifest file for your application or package.

The emulator seem to cache this preview even if you uninstall and reinstall the package. You may want to restart your emulator to see this effect.

Emulator also provides a way to take a screen shot of your widget look by explicitly invoking the configurator and capture the resulting widget view. You can invoke this application by looking at the app list and locating the widget preview. This app will then allow you to choose the widget that you want to preview at which time you will see the widget configurator to kick in. At the end you will see a sample widget view. the widget preview application then will allow you take a screen shot and send you an email of the file.

Or you can just provide any iconified preview image instead. that is all there is to this preview idea. Just an icon. How you get it is upto you.