Android: AppWidget with custom view not working

I pretty much left my custom view intact, and implemented an ImageView for my widget, then rendered the view using the getDrawingCache()

MyView myView = new MyView(context);
myView.measure(150,150);
myView.layout(0,0,150,150);
myView.setDrawingCacheEnabled(true);
Bitmap bitmap=myView.getDrawingCache();
remoteViews.setImageViewBitmap(R.id.dial, bitmap);

Leave a Comment