How to hide activity from menu?

by f...@r@0n » Mon, 12 Oct 2009 02:48:48 GMT


Sponsored Links
 Hello guys,

Does anybody know how to hide activity icon from menu? I am trying to
write simple multiview application. So, I have two activities there,
the first (main) activity starts the second one. However, my second
activity icon is visible in installed apps menu grid and can be
started from menu as separate standalone app :)
Is there any special activity tag I can use in manifest to hide icon?

Thanks.

Br,
 Faraon

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



How to hide activity from menu?

by Mark Murphy » Mon, 12 Oct 2009 03:07:02 GMT


 


In the AndroidManifest.xml file, both of your activities probably have
an <intent-filter> element that looks like:

<intent-filter>
        <action android:name="android.intent.action.MAIN" />
        <category android:name="android.intent.category.LAUNCHER" />
</intent-filter>

That tells Android to put an icon in the Launcher for that activity.
Remove that <intent-filter> from any activity that is not supposed to be
in the Launcher.

-- 
Mark Murphy (a Commons Guy)
 http://commonsware.com  |  http://twitter.com/commonsguy 

Need Android talent? Ask on HADO!  http://wiki.andmob.org/hado 

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


Sponsored Links


How to hide activity from menu?

by f...@r@0n » Mon, 12 Oct 2009 22:35:01 GMT


 Yeah, removing LAUNCHER category works fine. This is what I need.

Such kind of things always happen when copy-paste code without clear
understanding what you are doing. Will try to avoid this in future :)

Thanks again!

f...@r@0n
--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. Android emulator colour format

Hi,

Android emulator uses which colour format for displaying video data ?
Is it RGB 565 ? or some thing else ? I tried with RGB 565 but i see
the image blurred. Colours look different for what exactly it has to
be.

Can any one clarify ?

Regards
Girish
--~--~---------~--~----~------------~-------~--~----~

2. Problem with sound on Notifications on Emulator


(...)



This is the second time in as many days I see somebody trying to access a
resource that way. Is there some misguided tutorial somewhere that claims
that this works, or is the documentation misleading in some way?

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

3. Idea for non-US/UK developers with paid apps (was Setup Merchant Account link now available)

4. Problems with creating a Hello World Application for Android

5. Cannot use custom style that inherit from translucent android theme

6. package isn't signed correctly error on customer install - Market problem??

7. playing video from browser in sdk1.1