Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Work around ListField painting issue in early versions of BlackBerry Device Software version 4.2.2

by Retired ‎02-16-2010 03:13 PM - edited ‎09-16-2010 02:45 PM (1,289 Views)

Summary

 

This article applies to the following:

  • BlackBerry® 8830 World Edition smartphone
  • BlackBerry® Curve™ 8300 smartphone
  • BlackBerry® Device Software version 4.2.2

Description

 

Early versions of BlackBerry Device Software version 4.2.2 have an issue with painting ListField UI objects and scrolling. When the cursor is on odd-numbered lines, starting with the first line, the object is not painted. Scrolling to an even-numbered line causes the entire object to be painted.

 

You can work around this issue by not using the HORIZONTAL_SCROLL style in the Manager, as shown below.

 

 

private static final

class TestScreen extends MainScreen {
         private final ObjectListField listField = new ObjectListField(USE_ALL_WIDTH);
         private final String[] lines = { "Line 1", "Line 2", “Line 3", "Line 4", "Line 5", "Line 6" };
         private TestScreen() {
                  super(DEFAULT_MENU | DEFAULT_CLOSE);
                  final Manager man = new VerticalFieldManager(VERTICAL_SCROLL | VERTICAL_SCROLLBAR);
                  add(man);
                  man.add(listField);
                  listField.set(lines);
        }
}

 

 

Contributors
Users Online
Currently online: 30 members 5,924 guests
Please welcome our newest community members: