BlackBerry Forums Support Community
              

Closed Thread
 
Thread Tools
Old 08-14-2008, 09:47 AM   #1
ilh3-
Knows Where the Search Button Is
 
Join Date: Mar 2008
Model: 8300
PIN: N/A
Carrier: O2
Posts: 17
Default Background colour showing through field background

Please Login to Remove!

Hi all,

I've created a custom MainScreen which adds a VerticalFieldManager with a custom background colour to the screen.

I've also created a custom VerticalFieldManager that looks like some of the new 4.5 screens with the white cells with rounded corners.

ListFields look fine when added to my custom vfm, which is added to my custom main screen, but then when I scroll through the list the background colour of the row that's just been scrolled off turns to the screen background colour rather than back to white.

Also I have custom BasicEditFields that pass on focus to the next field when the trackball is clicked or the enter key is pressed and on 1 of my screens with these on using the custom mainscreen and vfm all but 2 (bizarre) leave the background colour where the cursor was when you press the trackball or enter.

If I scroll past the edge of the screen or bring up the menu, they then go back to the correct white background.

Anyone have any idea how to stop this?

(Should see the background next to "asda" and the first row in the ListField)
Attached Images
File Type: jpg screen.JPG (19.4 KB, 41 views)
Offline  
Old 08-14-2008, 10:53 AM   #2
jfisher
CrackBerry Addict
 
Join Date: Jun 2005
Location: Manchester, UK
Model: BOLD
Carrier: t-mobile
Posts: 714
Default

something like this may work, force a repaint:

Code:
  
public static class myCustomListField extends ObjectListField {

      protected boolean navigationMovement(int dx, int dy, int status, int time) {
            this.invalidate(this.getSelectedIndex()); 
            return false;
        }
    }
__________________
new job doesn't allow a public profile - please do not contact this user with questions, you will not get a response. good luck!
Offline  
Old 08-15-2008, 09:48 AM   #3
ilh3-
Knows Where the Search Button Is
 
Join Date: Mar 2008
Model: 8300
PIN: N/A
Carrier: O2
Posts: 17
Default

Thanks for that, worked a treat...sorta. Tried a custom ListField and only overriding that like you showed but it didn't work for some reason although strangely enough adding it when creating a ListField worked. E.g for anyone who might want to know in the future:

Code:
ListField lf = new ListField()
{
    protected boolean navigationMovement(int dx, int dy, int status, int time)
    {
        this.invalidate(this.getSelectedIndex()); 
        return false;
    }
};
Cheers, also inspired the solution to BEFs showing the background colour too.

Last edited by ilh3-; 08-15-2008 at 09:49 AM..
Offline  
Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


Lot of 6 Vintage Apple Drawstring Bags For iPhone, Mac, Apple Watch, iPod picture

Lot of 6 Vintage Apple Drawstring Bags For iPhone, Mac, Apple Watch, iPod

$45.00



Vintage Apple Computer 4” Paper Cube Notepad Macintosh 80s 90s Office White picture

Vintage Apple Computer 4” Paper Cube Notepad Macintosh 80s 90s Office White

$39.95



Apple 1 Replica IC's: Vintage IC’s Many Types See List NOS 74XXX Types - Apple I picture

Apple 1 Replica IC's: Vintage IC’s Many Types See List NOS 74XXX Types - Apple I

$20.00



Vintage 90’s APPLE Colorbok Journal 100 Lightly Lined Pages Hardcover 6”x5” NOS picture

Vintage 90’s APPLE Colorbok Journal 100 Lightly Lined Pages Hardcover 6”x5” NOS

$5.99



VINTAGE 1994 Apple Black Toner Laser Writer Cartridge M 2473 G/A NEW SEALED picture

VINTAGE 1994 Apple Black Toner Laser Writer Cartridge M 2473 G/A NEW SEALED

$25.95



C2102A-4 INTEL VINTAGE 1K SRAM 1024Bit CERAMIC GOLD PINS APPLE 1, DC1976 Mimeo-1 picture

C2102A-4 INTEL VINTAGE 1K SRAM 1024Bit CERAMIC GOLD PINS APPLE 1, DC1976 Mimeo-1

$31.77







Copyright 2004-2016 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.