Launching the Xperia Z alarm clock
Asked Answered
A

2

0

I'm using this block of code to launch the default Alarm Clock when tapping on my clock widget.

public Intent getAlarmPackage(Context context)
{
    PackageManager packageManager = context.getPackageManager();
    Intent AlarmClockIntent = new Intent(Intent.ACTION_MAIN).addCategory(Intent.CATEGORY_LAUNCHER);

    String clockImpls[][] = {
            { "Standard Alarm", "com.android.alarmclock",
                    "com.android.alarmclock.AlarmClock" },
            { "HTC Alarm ClockDT", "com.htc.android.worldclock",
                    "com.htc.android.worldclock.WorldClockTabControl" },
            { "Standard Alarm ClockDT", "com.android.deskclock",
                    "com.android.deskclock.AlarmClock" },
            { "Froyo Nexus Alarm ClockDT",
                    "com.google.android.deskclock",
                    "com.android.deskclock.DeskClock" },
            { "Moto Blur Alarm ClockDT",
                    "com.motorola.blur.alarmclock",
                    "com.motorola.blur.alarmclock.AlarmClock" },
            { "Samsung Galaxy S", "com.sec.android.app.clockpackage",
                    "com.sec.android.app.clockpackage.ClockPackage" } };

But this is not working with the Sony Xperia Z. Any suggestions?

Annalee answered 17/7, 2013 at 17:21 Comment(0)
T
2

After some search i managed to find corresponding Activity:

{ "Sony Ericsson Xperia Z", "com.sonyericsson.organizer", "com.sonyericsson.organizer.Organizer_WorldClock" }   

As alternative com.sonyericsson.organizer also contains - com.sonyericsson.alarm.SetAlarm

Technetium answered 23/11, 2013 at 20:34 Comment(0)
S
0

Organizer_WorldClock opens a world clock. To open a list of alarms is better to use just Organizer

{ "Sony Ericsson Xperia Z", "com.sonyericsson.organizer", "com.sonyericsson.organizer.Organizer" }
Semidome answered 28/12, 2014 at 17:9 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.