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

Reply
Developer
Posts: 1,636
Registered: ‎07-14-2008
My Device: Z10
My Carrier: Fido
Accepted Solution

HorizontalFieldManager question

I have the following for displaying the days of the week  checkboxes

 

    public HorizontalFieldManager ffm_days = new HorizontalFieldManager(Field.FIELD_LEFT);

 

    ffm_days.add(days[i])

   this.add(ffm_days)

 

this works fine on all the OSes but NOT on OS6.

 

the screen would display the following checkboxes horizontally

 

S M T W T F S

 

but on the Torch it only shows S checkbox and the reset are somewhere on the right side which i can not scroll or see.

 

what is the best way to have the checkboxes grouped and displayed horizontally? thx

Highlighted
Developer
Posts: 723
Registered: ‎03-12-2009
My Device: Playbook

Re: HorizontalFieldManager question

On 6.0 checkboxes use all width by default.

 

You have to override the checkboxes layout method and set the extent to getPreferredWidth() of the checkbox to have same behavior as 5.0 and below.

 

This fix does not break previous OS impl. either.