Regarding short cut icon

by Guru » Thu, 01 Oct 2009 00:50:51 GMT


Sponsored Links
 I found this peice of code for creating short-cut at the dektop:




  Intent shortcutIntent = new Intent
(Intent.ACTION_MAIN);
                shortcutIntent.setClassName(this, this.getClass
().getName());

                Intent intent = new Intent();
                intent.putExtra(Intent.EXTRA_SHORTCUT_INTENT,
shortcutIntent);
                intent.putExtra(Intent.EXTRA_SHORTCUT_NAME, "hello");
                Parcelable iconResource =
Intent.ShortcutIconResource.fromContext(
                        NoteView.this,  R.drawable.short_icon);
                intent.putExtra(Intent.EXTRA_SHORTCUT_ICON_RESOURCE,
iconResource);
                intent.setAction(Intent.ACTION_CREATE_SHORTCUT);
                getApplicationContext().sendBroadcast(intent);




I wanted to know is there any way of giving a Bitmap as the short-cut
icon,instead of an existing drawable in the resource folder.

-- 
Thanks and Regards
Gurudutt P.S.

--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. HELP! Magic ga mau booting

Dear RR,
As subject kenapa yah?
Kejadiannya tadi pagi update ROM SuperD 10.3 langsung hajar dari versi SuperD 
10. Tapi malah nyangkut dilogo htc Magic aja.
Udah coba wipe flashing, restore nandroid, flash cyanogen 4.15 tp tetap 
nyangkut. 
Mohon petunjuk RR..

@ade_ghufron
Sent from BlackBerry on 3

-- 
"Indonesian Android Community [id-android]" 

2. Android 1.5 marketshare is increasing

The "Android Device Dashboard"

4 January 2010:

Android 1.1   0.3%
Android 1.5   31.0%
Android 1.6   47.6%
Android 2.0   0.7%
Android 2.0.1   20.4%

12 April 2010:

Android 1.1   0.1%
Android 1.5   38.0%
Android 1.6   31.6%
Android 2.0   0.3%
Android 2.0.1   2.7%
Android 2.1   27.3%

Thankfully, the pre-2.0 share is shrinking overall.

But the share for 1.5 *grew* from 31% to 38%. That can't be good.

P. V. Nasby

-- 

3. How many different market rankings are there?

4. Calon X10 users?

5. How to fix N D R IV E missing image file error was: Aplikasi GPS untuk Hero

6. Android animation not firing immediately

7. Spinner getting selected string