During creation of Widget views(RemoteViews) I'm trying to set
"actions" for inner View objects such as ImageView, LinearLayout and
others. But some calls are being processed correct but others are
throw exceptions. Simple code from update widget method example is
below.


RemoteViews widgetViews = new RemoteViews(context.getPackageName(),
                R.layout.widget_layout);

//this call is correct
widgetViews.setInt(R.id.ClientLayout05, "setVisibility",
View.INVISIBLE);


//the following code writing to LogCat
//updateAppWidget couldn't find any view, using error view
//android.widget.LinearLayout can't use method with //RemoteViews:
setBackgroundResource(int)"
widgetViews.setInt(R.id.ClientLayout05, "setBackgroundResource",
R.drawable.background_widget_button_transparent);

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to