Start from Android 3.1, API Level 12, support resizeable home screen widget. To specify a Home Screen Widget as resizeable, include android:resizeMode in App widget provider XML, /res/xml/widgetproviderinfo.xml in our example.
<appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"
android:minWidth="146dp"
android:minHeight="72dp"
android:updatePeriodMillis="1800000"
android:initialLayout="@layout/widget_layout"
android:configure="com.example.androidhomewidget.ConfigureWidgetActivity"
android:resizeMode="horizontal|vertical">
</appwidget-provider>
To resize the widget, touch-hold it to show its resize handles, then drag the horizontal and/or vertical handles to change the size on the layout grid.
0 Response to "Home Screen Widget step-by-step - resizeable home screen widget"
Posting Komentar