There is no standard alarm clock API in the platform.  Heck, some devices
may not even have one.

On Thu, Mar 11, 2010 at 12:23 AM, Thomas <thomas.erme...@gmail.com> wrote:

> I have a widget that should launch the AlarmClock when its clicked.
> After searching for a result it seems to me that every phone can have
> its own AlarmClock-application, and that what I am trying to do isnt
> really possible?
>
> I have been using this for HTC Hero:
> i.setClassName("com.htc.android.worldclock",
> "com.htc.android.worldclock.WorldClockTabControl");
> resolved = packageManager.resolveActivity(i,
> PackageManager.MATCH_DEFAULT_ONLY);
>
> And this if not HTC Hero:
> i.setClassName("com.android.alarmclock",
> "com.android.alarmclock.AlarmClock");
> resolved = packageManager.resolveActivity(i,
> PackageManager.MATCH_DEFAULT_ONLY);
>
> This way I can check if the AlarmClock application is there. But now
> it seems that the Nexus One has yet another application. Does anyone
> know the component name and class for the Nexus AlarmClock?
>
> I can see that this will be a growing list of checks, so is there a
> better way?
>
> Thomas
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com<android-developers%2bunsubscr...@googlegroups.com>
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to