Skip to main content

Home/ Android Dev/ Group items tagged news

Rss Feed Group items tagged

Vincent Tsao

How to implement a Button on an Android Widget - Stack Overflow - 0 views

  • I am just getting started with Android development and I have created a nice little widget that displays some info on my home screen. However, I now want to implement a Button on my widget that updates the info in my widget TextView.
  • Solved - I can confirm that an Activity is NOT needed if you want create a Button to update an Android AppWidget. I have been able to implement my AppWidgetProvider class such that it registers an android.appwidget.action.APPWIDGET_UPDATE intent-filter with the Broadcast receiver in the AndroidManifest.xml, which then fires the onUpdate event in the AppWidgetProvider class (which in turn then runs the UpdateService).
  • The UpdateService in my AppWidgetProvider class then uses onHandleIntent to run a private buildUpdate method - which registers the onClick event with a call to setOnClickPendingIntent as follows:
  • ...1 more annotation...
  • // set intent and register onclickIntent i = new Intent(this, MyWidget.class);PendingIntent pi = PendingIntent.getBroadcast(context,0, i,0);updateViews.setOnClickPendingIntent(R.id.update_button,pi);
Vincent Tsao

Android 2.2 demolishes iOS4 in JavaScript benchmarks - 1 views

  • We compared these findings with that of our tests of Apple's mobile Safari browser on the iPhone 4. The results show that the Android device delivers significantly faster JavaScript execution than the iPhone, scoring over three times better on V8 and almost twice as fast on SunSpider
  •  
    总是有这类比较Froyo和其他OS渲染JS性能的评测,难道是Google在鼓励更多web app运行在android浏览器下?
Vincent Tsao

How to handle screen orientation change when progress dialog and background thread acti... - 0 views

  • When you switch orientations, Android will create a new View. You're probably getting crashes because your background thread is trying to change the state on the old one. (It may also be having trouble because your background thread isn't on the UI thread) I'd suggest making that mHandler volatile and updating it when the orientation changes.
Vincent Tsao

HTC Magic will get Android 2.2, According to SFR | Android Community - 0 views

  • Most Android Smartphones released this year will receive the Android 2.2 Froyo. If you have a 2009 HTC Magic, then you might receive the Android 2.2 Froyo as well. France’s 2nd largest largest mobile carrier SFR officially announced the Magic will be receiving the Froyo update.
  • T-Mobile USA said the myTouch 3G, basically the same thing as a HTC Magic would be updated with Froyo a bit later this year. So it looks like the old Magic will be receiving the new Google OS in the next few months.
Vincent Tsao

putExtra error on AppWidget - Android Developers | Google Groups - 0 views

  • I am just making some AppWidget and I want to pass some Strings through UpdateView to an Activity. But the Bundle is null. I try this: -Widget.java                       Intent defineIntent = new Intent(context, Visor.class);                        defineIntent.putExtra ("org.rss.androides.post2","artist");                        PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, defineIntent, 0);                        updateViews.setOnClickPendingIntent (R.id.widget, pendingIntent); -Viewer.java           Bundle b = intent.getExtras();                 if (b == null) {                     finish();                     return;                 } b is always null.
  • Remember that PendingIntents aren't keyed using extras: http://groups.google.com/group/android-developers/msg/b296f43ae70c4587 You could hack the extras through by mangling them into Uri parameters, or if you're using a ContentProvider, just point to a specific row.
  • Or use PendingIntent.FLAG_UPDATE_CURRENT; just be careful that each active instance has its own unique Intent.
Vincent Tsao

Palm用户体验大师加盟谷歌Android团队_Palm_cnBeta.COM - 0 views

  • 惠普旗下的Palm公司已确认,公司副总裁、webOS UI设计负责人、著名移动用户体验设计大师Matias Duarte将离职。而来自Google方面的消息,Duarte将加入Google,出任Android用户体验总监一 职。由于历史上Matias Duarte在跳槽时,总是带着自己的团队同行,所以很可能Palm原设计团队的其他人也会随之而去。这其实并不奇怪,Duarte本来就是 Android之父Andy Rubin 2000年创办的公司Danger的设计总监。 2005年Danger被微软收购后(最近推出的Kin手机来自Danger),Duarte加盟 Helio公司(由EarthLink与SK合资创办,现在是Springt-Nextel的一部分)任副总裁,负责体验设计。2007年加盟Palm, 主导webOS的UI设计。无论是Danger、Helio还是Palm webOS,其界面设计都广受好评,可惜产品本身生不逢时。尤其是webOS, 曾被许多开发者称为在创新性上唯一能与iPhone相提并论的操作系统。
  • Matias Duarte,在产品管理、信息架构、交互设计、视觉设计、用户研究等领域均有很深造诣的设计大 师。1996年毕业于马里兰大学。拥有计算机科学学位,并辅修了艺术和艺术史。大学期间曾经开发了一款免费游戏软件,并连续三年获得Linux Journal的读者选择奖。1996年为Atari公司(乔布斯曾经在此打工)的游戏担任过主设计师。1997年在创业公司 MagicArts任合伙人兼设计副总裁。2000年加入Danger,任设计总监,领导了SideKick产品的设计。2005年加盟Helio。 2007年加盟Palm。 曾荣获2002年Wired Rave大奖,美国国家设计奖提名,拥有9个美国实用专利和2个设计专利。 他的自我介绍上这样描述自己的目标:To create great products that make people smile.(创造使人微笑的优秀产品。)
Vincent Tsao

Android 2.1′s speech-to-text feature reviewed - it's "OK", just about » EuroD... - 0 views

  • Their conclusion is that Android 2.1′s new speech-to-text thing works, just about, although there’s a delay of a few seconds while the phone crunches your spoken words and tries to get the gist of what you’re saying – and a few errors sneak in, particularly when dealing with those smaller words we tend to hurry over. Basically, it looks like you have an awkward choice to make – speak your messages then spend a bit of time awkwardly tidying up the few errors that will inevitably sneak in, or carry on as normal with traditional text input methods.
Vincent Tsao

Adding items to a ListView - Android Developers | Google Groups - 0 views

  • SizzlingSkizzorsProgrammer wrote: > After the listview is already initialized, is it possible to add items > to it during runtime? Just add the new items to the adapter, or the data source that backs up the adapter (if it's a CursorAdapter).
Simon Pan

Application Fundamentals | Android Developers - 0 views

  • passes
  • When onReceive() returns
  • by the system at any time
  • ...13 more annotations...
  • to start a service
  • presents
  • memory paging state
  • Broadcast receiver lifecycle
  • The activity at the top of the stack is one that's currently running
  • The root activity in the stack is the one that began the task
  • Suppose
  • keeping both activities in the same task.
  • Tasks
  • A task is a stack of activities, not a class or an element in the manifest file.
  • The current task goes into the background and the root activity for the new task is displayed.
  • Rather
  • the previous activity in the same task is displayed.
Vincent Tsao

Android Dev Phone, Ubuntu and VMWare Server : Johan de Koning - 0 views

  • Create a new file (as root) sudo gedit /etc/udev/rules.d/50-android.rules with the following content SUBSYSTEM=="usb", SYSFS{idVendor}=="0bb4", MODE="0666" Make sure that the text after {idVendor} is the same as the device id found when using the lsusb command. Save and exit the editor To make execution of the rule possible, perform a chmod sudo chmod a+rx /etc/udev/rules.d/50-android.rules To make the rule active, restart udev sudo /etc/init.d/udev restart
  • You can perform a check, to see that the Android Dev Phone is shared with Ubuntu, by opening a Terminal (inside Ubuntu. Open a VMWare Remote Console to make use of the Ubuntu) and type the following command lsusb A list of USB devices will be shown. For example: Bus 002 Device 001: ID ld6b:0001 Linux Foundation 1.1 root hub Bus 001 Device 004: ID 0bb4:0c02 High Tech Computer Corp. Bus 001 Device 001: ID ld6b:0002 Linux Foundation 2.0 root hub
Vincent Tsao

Android :Google 收入的生命线 | 爱范儿: 拇指资讯小众讨论 - 1 views

  • 据市场调研公司尼尔森的统计,过去六个月,Android 已经超越 BlackBerry  OS 和 IOS 成为美国消费者购买智能手机的首选。如图,Android 在今年四月超越了一直低迷的  IOS 之后,在七月份又超越了持续下滑的BlackBerry  OS 。但从市场总份额来看,黑莓仍占主导地位
  • 面对这一骄人的数字,Google 的 CEO 施密特倒是显得荣辱不惊。他表示,尽管并不直接从 Android 获利,但是基于 Android 的手机已产生足够的广告收入,足以支撑 Android 的开发成本
  • 随着 Android 手机的大幅增长,由 Android 带来的广告业务有望每年为公司带来“高达100亿美元的收入”。而这一数字将是 Google 今年总营收的一半。 此前在接受《华尔街日报》的采访时,施密特曾表示,他希望有朝一日能有 10 亿 的 Android 手机用户。这样,只要每个用户每年消费 10 美元,就能达到这个目标
Vincent Tsao

Nexus Two配置及Android 2.3特性新消息_Google Android_cnBeta.COM - 0 views

  • 另外关于Android 2.3版系统的特性也有了新的消息,在姜饼系统中主要针对电源管理做了优化,可以让手机的续航时间得到大幅度的提升,新系统将提供一个新的拨号界面以及用户界面系统的整体性调整,并加入了视频聊天功能
  • Android开发团队还制作了一个全新的复制粘贴系统(不仅仅是文本的复制粘贴),系统集成的社交网络功能得到完善,Google新推出的WebM视频格式也将会得到支持
Vincent Tsao

Android YouTube app Play Video Intent - Stack Overflow - 1 views

  • Intent videoClient = new Intent(Intent.ACTION_VIEW);    videoClient.setData(Uri.parse("http://m.youtube.com/watch?v="+videoId));    videoClient.setClassName("com.google.android.youtube", "com.google.android.youtube.PlayerActivity");    startActivityForResult(videoClient, VIDEO_APP);
Vincent Tsao

Help getting array from arrays.xml file (Android, Eclipse) - Stack Overflow - 0 views

  • I am just trying to display a list from an array that I have in my arrays.xml.
  • String[] testArray = getResources().getStringArray(R.array.testArray); /** Called when the activity is first created. */ @Override protected void onCreate(Bundle savedInstanceState)
  • You can't initialize your testArray field this way, because the application resources still aren't ready.
  • ...1 more annotation...
  • protected void onCreate(Bundle savedInstanceState) {    super.onCreate(savedInstanceState);    // Create an ArrayAdapter that will contain all list items    ArrayAdapter<String> adapter;    mTestArray =  = getResources().getStringArray(R.array.testArray);        /* Assign the name array to that adapter and     also choose a simple layout for the list items */     adapter = new ArrayAdapter<String>(    this,    android.R.layout.simple_list_item_1,    mTestArray);    // Assign the adapter to this ListActivity    setListAdapter(adapter);    }}
Vincent Tsao

spinner :: anddev.org - Android Development Community | Android Tutorials - 0 views

  • spnCountries.setAdapter(aspnCountries); spnCountries.setOnItemSelectedListener(spnCountriesListener); private Spinner.OnItemSelectedListener spnCountriesListener =   new Spinner.OnItemSelectedListener() {     public void onItemSelected(AdapterView parent, View v, int position, long id) {       Log.i("print", parent.getSelectedItem().toString());     }     public void onNothingSelected(AdapterView parent) { }              };
‹ Previous 21 - 40 of 62 Next › Last »
Showing 20 items per page