BlackBerry API equivalent to Android's Toast?
android, blackberry, java-me
Solution
You can try using the BlackBerry `Status` class. See API docs here
Something like this:
// show a status message for 5 seconds (5000 msec)
Status.show("Hello Toast", Bitmap.getPredefinedBitmap(Bitmap.INFORMATION), 5000);
It's going to be a bit bigger and more intrusive than an Android Toast, but BlackBerry users have seen these before. In general, it's best not to try to emulate one platform exactly, when writing apps for another. Stick with what that platform's users are used to. This should be close enough.
If it's not exactly what you want, you'll probably need to implement your own `Field` or `Manager` subclass to get exactly the size, look and feel that you need.
Problem
I need similar behavior to the Android Toast message in my BlackBerry App. For a hardcoded short interval of time, the message has to be shown on the screen. If the UI stalls for that particular period, it's fine. But the message should not expect user's interaction to get it closed as in Blackberry's Dialog.alert(), instead it should close automatically. Does this exist on BlackBerry already?