I make appWidget with listView. For this I need use RemoteViews. And when I init appWidget ListView I set adapter and empty view (when no content):
remoteViews.setEmptyView(R.id.listViewWidget, R.id.empty_view);
But my emptyView contains button, and I need to set OnClickListener for it. How I can do that?
You would need setOnClickPendingIntent
.
remoteviews.setOnClickPendingIntent(button_id, pendingIntent);