프로그래밍 정리/안드로이드

위젯 Refresh

주누다 2012. 6. 25. 10:45
반응형

/**

* 위젯 Refresh

*/

private void setWidgetRefresh(){

RemoteViews views = null;

ComponentName showWidget = null;

AppWidgetManager widgetManager = AppWidgetManager.getInstance(TalkTalkWidgetProvider.allContext);

showWidget = new ComponentName(TalkTalkWidgetProvider.allContext, TalkTalkWidgetProvider.class);

views = new RemoteViews(TalkTalkWidgetProvider.allContext.getPackageName(), R.layout.appwidget_provider);

widgetManager.updateAppWidget(showWidget, views);

}

반응형