위젯에 이미지 하나를 넣은 다음 다른 이미지로 클릭하면 어떻게 바뀌나요? ImageButton 만있는 위젯입니다. 그러나 이것 이후에 어디로 가야할 지 모르겠습니다. 보류중인 의도에 대해 모두 알고 있지만, 여기에 도움이되지 않습니다. 뭔가를 놓치지 않으면 ... 여기에 내 onUpdate가 있습니다.위젯의 이미지 변경
public void onUpdate(Context context,AppWidgetManager appWidgetManager,int[] appWidgetIds){
RemoteViews remoteViews = new RemoteViews(context.getPackageName(), R.layout.widget);
PendingIntent onPendingIntent = PendingIntent.getService(context, 0, new Intent(context, widgetService.class), 0);
remoteViews.setOnClickPendingIntent(R.id.ImageButton01, onPendingIntent);
appWidgetManager.updateAppWidget(appWidgetIds, remoteViews);
}
을 찾고 무엇을 생각 – urSus