intent.action_send and intent chooser

by tnull » Tue, 20 Jul 2010 22:20:44 GMT

Sponsored Links
 When creating an intent with action send to send some data, is there a
way to filter the results that are included in the activity chooser
that is created using Intent.createChooser? I have not seen a way to
do this other than setting the mime type, but it is not flexible

For example, there is a situation when I want e-mail apps to be the
only results in the activity chooser dialog. Setting the type to "text/
html" successfully filters this down to email apps, except when
bluetooth is enabled. Bluetooth appears in the list as well, but this
is not desirable. Surely there is a way to have a little more control
over the results?


intent.action_send and intent chooser

by Mark Murphy » Tue, 20 Jul 2010 22:31:06 GMT


What are "e-mail apps"?

Only on your test environment(s). Anyone can create an application
that supports ACTION_SEND of text/html -- this it not something
exclusive to "e-mail apps". I would not be the least bit surprised if
there are others on certain devices or out on the Market.

Write your own chooser dialog, using PackageManager.

Mark Murphy (a Commons Guy)  |  | 

_The Busy Coder's Guide to Android Development_ Version 3.1 Available!


Sponsored Links

intent.action_send and intent chooser

by tnull » Tue, 20 Jul 2010 23:39:13 GMT

 With e-mail apps, I just meant I was looking to filter the results to
e-mail clients, not necessarily anything that can handle "text/html",
which I realized wouldn't work when bluetooth popped up.

Thank you for the tip on creating my own dialog using PackageManager,
I will look into that.


Other Threads

1. JIT compilation on Dalvik VM

Hi all ,

I have 2 question about the JIT compiler on Android Froyo list below :


Does anyone know where is the code for interpreter to
  a) invoke the JIT'ed code
  b) return from JIT'ed code
I have trace the code of interpreter for a long time , but still
cannot find the (a) part ,


According to the slide about JIT compiler from GOOGLE I/O 2010 ,
there are trace JIT and method JIT when we are in different
situation ,
I want to test my App and run in the method JIT mode on emulator
(using Froyo with JIT enabled system image ).
but inside the code I found that there is no transition point to force
the JIT style change from trace to method .
I have try to manually set the WorkOrderKind to method (default is
trace ) when the JIT compiler enqueues a CompileWorkOrder
but the result is emulator crash.
Is there anybody know why ?



2. Accelerometer not working when screen turns off

As I understand it, there seems to have been a change in the OS that
prevents the accelerometer from running when the screen turns off and
the phone CPU goes into its power saving state.  Can this be
confirmed?  I have gotten around this by using a wake lock, but this
is a much less than ideal solution as it drains a lot of battery.

If the accelerometer was disabled in low power mode to save the
battery, it may very well have the opposite effect in many cases, such
as mine. A partial wake lock seems to be required to keep it running,
which is obviously much worse than if just the accelerometer were
running without the need for the wake lock.

Are there any other workarounds anyone knows of to getting
accelerometer values while the phone is in low power mode?  Also, are
there any plans to change this in future versions of the OS?  If there
are no plans to change this, I would definitely like to petition for
this to be changed.

Thoughts?  Ideas?  Workarounds?  Thank you!!


3. Application Background

4. for the implementation of g729 ion ad\ndroid.2.1.

5. Can non-market app be updated from a market app later?

6. Will user get notified of market update that matches package of a previously installed non-market app?

7. Want titles different on home icon versus activity