Jeff, is there a list of classes that are prohibited? Looks like TableLayout is also on the no-fly list.
On Apr 17, 1:17 pm, Jeff Sharkey <jshar...@android.com> wrote: > Yes, that's working as intended. There are unsolved issues with how > to get EditText content back across PendingIntent boundaries, so we > aren't allowing EditText in widgets for 1.5. We're looking for a way > to solve this in future releases. > > As a workaround, you could link your widget to launch a Theme.Dialog > activity that contains the EditText. And removing the EditText from > your layout should allow the widget to inflate correctly. > > j > > 2009/4/16 daen <sz.d...@gmail.com>: > > > > > > > I downloaded the android 1.5 SDK. > > And I found that we can simply add a widget into the Android > > Homescreen with the java class android.appwidget.AppWidgetProvider. > > > use this layout i can add my own widget successfuly。 > > > <?xml version="1.0" encoding="utf-8"?> > > <LinearLayout xmlns:android="http://schemas.android.com/apk/res/ > > android" > > android:orientation="vertical" > > android:layout_width="fill_parent" > > android:layout_height="fill_parent" > > > <TextView > > android:layout_width="fill_parent" > > android:layout_height="wrap_content" > > android:text="Hello" > > /> > > </LinearLayout> > > > but when i change the TextView to EditText like this. > > The Android Home cannotload my widget. > > > 04-16 09:27:07.111: WARN/AppWidgetHostView(633): Caused by: > > android.view.InflateException: Binary XML file line #13: Classnot > >allowedto beinflatedandroid.widget.EditText > > > <?xml version="1.0" encoding="utf-8"?> > > <LinearLayout xmlns:android="http://schemas.android.com/apk/res/ > > android" > > android:orientation="vertical" > > android:layout_width="fill_parent" > > android:layout_height="fill_parent" > > > <EditText > > android:layout_width="fill_parent" > > android:layout_height="wrap_content" > > android:text="Hello" > > /> > > </LinearLayout> > > > any one can help me? > > -- > Jeff Sharkey > jshar...@android.com --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---