The preferred way is to use a long-press to bring up a context menu.  The
menu populated by pressing the menu button should be used for things that do
not require a selection.

----------------------------------------------------------------------
There are only 10 types of people in the world...
Those who know binary and those who don't.
----------------------------------------------------------------------


On Tue, Aug 25, 2009 at 9:30 AM, Martin Obreshkov <[email protected]>wrote:

>
> Thanks for the reply but if this is not the recommended way what is
> the solution for it. For example i have a list with mails and when i
> select given mail there are actions i can perform(delete, reply). What
> is the best way to implement this, should i use listview at all.
> Thanks in advance.
>
> On Tue, Aug 25, 2009 at 5:39 PM, Mark Murphy<[email protected]>
> wrote:
> >
> >> I have a listview and i want when i select a row to stay selected
> >
> > The core Android team does not recommend this.
> >
> >> The problem is that if i change some attribute ( for example
> >> v.setBackgroundColor(Color.BLACK) ) the selected view no longer stays
> >> selected.
> >
> > That is because "selected" is one of the background colors. A widget
> > background is usually some form of ColorStateList. You can supply a
> simple
> > color to setBackgroundColor(), but that only works if you do not intend
> to
> > allow the item to be selected, for example.
> >
> > --
> > Mark Murphy (a Commons Guy)
> > http://commonsware.com
> > Android App Developer Books: http://commonsware.com/books.html
> >
> >
> >
> > >
> >
>
>
>
> --
> When I raise my flashing sword, and my hand takes hold on judgment, I
> will take vengeance upon mine enemies, and I will repay those who haze
> me. Oh, Lord, raise me to Thy right hand and count me among Thy
> saints.
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to