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
Contributor
makahn64
Posts: 27
Registered: ‎09-29-2010
My Device: 9800 Torch
My Carrier: AT&T

Is the GridFieldManager useless?

I'm trying to do something I thought the GridFieldManager would be tailor made for:

 

Name: [ EditField]

Phone:  [EditField]

 

Using LabelFields (non-Focusable) in column 0 and EditFields (with no labels) in column 1.

 

I wanted everything in column 0 right justified with the ":" against the column 0-1 border and I wanted all of my EditFields to take up all of the width of column 1 with pretty little borders.

 

Something that would take me about 5 minutes for iPhone. (I say that because I get really, really pissed when I spend half a day doing something that is SO simple on other platforms.)

 

So my problems:

1) The EditField runs off the edge of column 1. This same field looks fine if I add it to the container VFM that holds the GridManager. No amount of mucking with column properties or overridding getPreferredWidth() etc. could fix this issue. I gave up and used some hack I found the BB website for creating fixed width/height EditFields. I emphasize *HACK because, really, how hard could it be to create a STANDARD EditField with a fixed width/height. Something many people would us.

 

I suspect there is a layout manager embedded in the cell that I can't seem to control.

 

2) Even though my LabelFields in column 0 are clearly Field.NON_FOCUSABLE (and work correctly when added to my container VFM instead of the GFM) they still accept focus. Again, I suspect there is some container these LabelFields are placed in that I cannot control that is focusable.

 

So my question iss: has anyone used GFM for anything other than simple tabular data? What am I missing? Am I wrong to be so pissed that when I write for BB, I spend SO MUCH **bleep** TIME on simple layout tasks???

 

 

 

 

 

Please use plain text.
Developer
dnepr
Posts: 723
Registered: ‎03-12-2009
My Device: Playbook

Re: Is the GridFieldManager useless?

Honestly, for any layout that is anything but basic... you're better off writing a custom layout manager.

Please use plain text.
Contributor
makahn64
Posts: 27
Registered: ‎09-29-2010
My Device: 9800 Torch
My Carrier: AT&T

Re: Is the GridFieldManager useless?

That seems to be the common wisdom and I've resorted to that before.

 

(I wonder how many iPhone or Android apps there would be if developers had to do every basic layout task like this on those platforms...)

Please use plain text.
Developer
dnepr
Posts: 723
Registered: ‎03-12-2009
My Device: Playbook

Re: Is the GridFieldManager useless?

Well....

 

Let me know how those checkboxes, radio buttons and drop down fields work on iPhone... oh wait.

 

 

Please use plain text.
Contributor
acmethunder
Posts: 13
Registered: ‎06-20-2011
My Device: Pearl 9100
My Carrier: Fido

Re: Is the GridFieldManager useless?

Let me know when the Blackberry gets good. Oh wait ...
Please use plain text.
Developer
RileyGB
Posts: 284
Registered: ‎08-06-2010
My Device: Z10

Re: Is the GridFieldManager useless?

The GridFieldManager that is "built-in" to OS5 is useless. It was not implemented in certain versions of OS5 (such as earlier OS versions of the Bold 2).

 

If you download the GridFieldManager implementation files and add them to your project, then it can be useful. But, it still requires a fair bit of TLC as navigation movement is not well defined in it.

 

 



Follow me on twitter @RileyGB - https://twitter.com/RileyGB
View my BB10 OpenSource projects - https://github.com/RileyGB/BlackBerry10-Samples
Please use plain text.
Contributor
acmethunder
Posts: 13
Registered: ‎06-20-2011
My Device: Pearl 9100
My Carrier: Fido

Re: Is the GridFieldManager useless?

Where can I get the implementation files.  I having GridFIeldManager issues, described here, and here.

Please use plain text.
Developer
RileyGB
Posts: 284
Registered: ‎08-06-2010
My Device: Z10

Re: Is the GridFieldManager useless?

http://www.assembla.com/code/psu-edu-sweng500/subversion/nodes/trunk/rimapp/src/com/thinkingblackber...


Follow me on twitter @RileyGB - https://twitter.com/RileyGB
View my BB10 OpenSource projects - https://github.com/RileyGB/BlackBerry10-Samples
Please use plain text.
Contributor
acmethunder
Posts: 13
Registered: ‎06-20-2011
My Device: Pearl 9100
My Carrier: Fido

Re: Is the GridFieldManager useless?

This looks promising, and very close to the way I have subclasses the stock GridFieldManager.  Any idea how this would relate to the problem I stated above?

Please use plain text.
Contributor
acmethunder
Posts: 13
Registered: ‎06-20-2011
My Device: Pearl 9100
My Carrier: Fido

Re: Is the GridFieldManager useless?

[ Edited ]

@searingmedia

This works.  How is it that a arranging screen elements in a grid would be this complicated.  In other words why must a grid field be made from scratch?

Thank you

Please use plain text.