Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I use the default dialog icons in my custom Blackberry popup dialog?

I'm writing a custom dialog window to display the status of a long operation, and would like to use the little timer icon (the little square clock on OS >= 4.6) that's used in the BB native dialogs.

How can I use this graphic within my dialog?

I'm already familiar with layout managers and such, I just don't know where the bitmap is, or if there's an API call to get the default theme icons like this.

like image 714
Ben S Avatar asked Jan 24 '23 04:01

Ben S


1 Answers

Under the Bitmap class there's an HOURGLASS constant defined that can be used with the getPredefinedBitmap() method.

Example:

Manager.add(new BitmapField(Bitmap.getPredefinedBitmap(Bitmap.HOURGLASS)));

This was pretty well hidden within the javadocs, so I figured I'd answer my own question in case anyone else needs to know.

like image 167
Ben S Avatar answered Jan 30 '23 00:01

Ben S