开发者

Hightlight image within a vertical manager

So i have 3 images in a vertical field manager and each image is clickable and proceeds to the correct url. all 开发者_如何学Pythonthat works. the only problem at this time is that when i scroll (up or down), i don't know which image is currently focused. i don't know until the browser opens the corresponding url.

so is there any way to get a border or a highlight to appear under my images (or within the manager) so that i can definitely see which image is currently focused? so if you think of a list, your selections are highlighted as you scroll up and down. i want something similar to that with my application.

thank you for your help.

ac


using the setSpace(int,int) method on the bitmap field worked great. this allowed me to see a border around the element that had focus.


override inline the bitmapfield drawFocus method. Something like this


protected void drawFocus(Graphics graphics, boolean on){
   graphics.setBackgroundColor(0x00204020);
   graphics.drawRect(0, 0, getBitmapWidth(), getBitmapHeight());
}

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜