如果看不惯博客排版,请点这里。
Android AppWidget如何支持复杂的View
一直想知道如何在AppWidget里面添加 ListView,EditText 这些复杂的View.我们知道要在AppWidget里添加 View都是通过RemoteView来做到了,然而RemoteView本身功能很弱,支持的操作很少,而且支持RemoteView的Widget很少:
在Dev Guide中有下面这段:
A RemoteViews object (and, consequently, an App Widget) can support the following layout classes:
* FrameLayout
* LinearLayout
* RelativeLayout
And the following widget classes:
* AnalogClock
* Button
…