On Thu, Jul 23, 2009 at 3:28 PM, Marco Nelissen<marc...@android.com> wrote:
> On Thu, Jul 23, 2009 at 11:19 AM, Kent Loobey <k...@uoregon.edu> wrote:
>>
>> On Thursday 23 July 2009 08:17:25 Mohamed Amir wrote:
>> > Is there a way to make the Toast last for longer time?
>> >
>> > I have tried this code
>> >
>> > Toast t = new Toast(this);
>> > View v = View.inflate(this, R.toast_layout, null);
>> > t.setView(v);
>> > t.setDuration(Toast.LENGTH_LONG);
>> > t.show();
>> > t.show();
>> > t.show();
>> >
>> > By calling show() method more than once, I hoped this would give a
>> > similar effect to lasting for longer time with some flickering, but I
>> > didn't see any difference.
>> > Is there some limit to the number of times that show() method can be
>> > called on the same Toast? e.g. just once per toast instance and
>> > further calling has no effect?
>> >
>> > Any ideas to increase that duration?
>>
>> Toast.makeText(mContext, "Some comment goes here.", 40000);
>
> That won't work, because the duration parameter is expressed in

I meant "is NOT expressed", of course.

> milliseconds, but as one of two constants.
> That being said, toasts are meant to be transient. If you need
> something on screen for an extended period of time, use an activity or
> dialog.
>

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

Reply via email to