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

Native Development

Reply
Developer
Posts: 155
Registered: ‎01-22-2010
My Device: PlayBook -> 9900, 9810, 9800, 9700,9000, 8800, 8700...
My Carrier: AT&T

Extending AbstractPane

I was looking to extend AbstractPane, in order to provide custom navigation pane functionality that doesn't extend from NavigationPane itself -- specifically because hte type of navigation I want to enable isn't compatible with NavigationPanes "stack" behavior .

 

However I noticed that the AbstractPane constructor requires that I supply an AbstractPanePrivate instance -- and I can't seem to find this defined anywhere.

 

Has anyone had luck extending AbstractPane, and if so how did you supply AbstractPanePrivate?



Try out BBSSH, a free Blackberry SSH client.
  • If you like my post, please let me know by Liking it!
  • If my post solved your problem please click on the Accept as Solution button.

BlackBerry Development Advisor (Retired)
Posts: 329
Registered: ‎05-07-2012
My Device: BB Alpha
My Carrier: N/A

Re: Extending AbstractPane

Hi there,

 

The only UI component you should extend is CustomControl, and encapsulate your navigationpane accordingly. Have you tried extending CustomControl?

 

If you feel that a specific control should come pre-packaged in the API, however, I would encourage a feature request here: https://www.blackberry.com/jira/secure/Dashboard.jspa

 

Martin

 

Developer
Posts: 155
Registered: ‎01-22-2010
My Device: PlayBook -> 9900, 9810, 9800, 9700,9000, 8800, 8700...
My Carrier: AT&T

Re: Extending AbstractPane

[ Edited ]

I'm trying to make what's best described as a circular carousel for navigating between panes/pages. This control would be a container for pages in the same way that NagivationPane and other AbstractPane-based controls are.

 

Such that if my pages are [A], [B], and [C], I would have a left-to-right swipeable navigation flow as follows:

 

[A] -> [B] -> [C] -> [A]

 

Or swiping right to left:

[A] -> [C] -> [B] -> [A]

 

 

 

Is this possible to do through a CustomControl derived class?



Try out BBSSH, a free Blackberry SSH client.
  • If you like my post, please let me know by Liking it!
  • If my post solved your problem please click on the Accept as Solution button.

BlackBerry Development Advisor (Retired)
Posts: 499
Registered: ‎05-07-2012
My Device: developer
My Carrier: developer

Re: Extending AbstractPane

I can't see why not.   A custom component that can be placed within a page seems right.

You can also try overlapping pages, using visibility or opacity to ensure only one is visible.

You can also have a page where you change the contents, but beware of object ownership.

 

If you find a great approach that works, please post the approach and consider writing a knowledge base article (or feeding us enough to write it for you).   This question has come up several times and several people are interested.

 

See also:

http://supportforums.blackberry.com/t5/Cascades-Development/Best-Practices-for-Switching-between-Vie...

There might also be other related threads.

 

Stuart