You are here Android > 开发者 > 开发讨论 > widget 按钮监听事件

机器人


93.089%

disconnected
登录后回复主题 | 跳到回复(1)

widget 按钮监听事件

... by 机器人 ... 29 月 9 天前 ... 398 次点击

请问在widget中如何设置一个按钮监听器.当用户单击时指定它跳出一个界面.请问如何写.谢谢大家!

1 - 9-15 11:04
wang492239163 地球
Intent intent1 = new Intent("up");
PendingIntent Pintent= PendingIntent.getBroadcast(getBaseContext(), 0, intent1, 0);
updateViews.setOnClickPendingIntent(R.id.B1, Pintent);
AppWidgetManager manager = AppWidgetManager.getInstance(this);
manager.updateAppWidget(thisWidget, updateViews);
看完之后有话想说?那就帮楼主加盖一层吧!

在回复之前你需要先进行登录
电子邮件或昵称
密码
当前热门主题  有谁想学习利用ksoap2连接webService远程接口吗? ... 12 篇回复
© 2009 A Nanshapo Production   -   About
a site powered by Project Babel