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

Web and WebWorks Development

Reply
Developer
Posts: 232
Registered: ‎01-30-2011
My Device: Dev Alpha C, Z10 LE
My Carrier: P4
Accepted Solution

[BB10] Title bar is not displayed

I have this code:

<div data-bb-type="screen" data-bb-effect="fade">
	<div data-bb-type="title" data-bb-caption="Test" data-bb-back-caption="Back" data-bb-action-caption="Go"></div>
	<ul id="main">
		<li>Option 1</li>
		<li>Other</li>
		<li>New</li>
		<li>About</li>
		<li>Feedback</li>
	</ul>
       <div data-bb-type="button" data-bb-style="stretch">Press me</div>
</div>

 and the title bar is not displayed, but for example button is displayed correctly...

 

Any idea?

All time online Smiley Very Happy
Developer
Posts: 2,462
Registered: ‎11-04-2010
My Device: Bold 9700

Re: [BB10] Title bar is not displayed

in your index.htm file, check to make sure this is commented out and supressed:

 

// Remove all titles "except" input and pill buttons screen if running on BB10
if (bb.device.isBB10 && (id != 'input') && (id != 'pillButtons')) {
	var titles = element.querySelectorAll('[data-bb-type=title]');
	if (titles.length > 0) {
		titles[0].parentNode.removeChild(titles[0]);
	}
}

 

This ships in the Kitchen Sink sample by default -- just get ride of that area and it should start showing up. Good luck!

J. Rab (Blog) (Twitter)
--
1. If you liked my post or found it useful please click on the thumbs up and provide a Like!
2. If my post solved your problem please click on the Accept as Solution button. Much appreciated!

Approved Apps: OnTrack | ssShots | Hangman
Developer
Posts: 232
Registered: ‎01-30-2011
My Device: Dev Alpha C, Z10 LE
My Carrier: P4

Re: [BB10] Title bar is not displayed

As always helpful - thank You, @JRab very much.

 

Guilty is Kitchen Sink - It would be better if I will be inspired by bbUI.js Smiley Wink

All time online Smiley Very Happy
Developer
Posts: 2,462
Registered: ‎11-04-2010
My Device: Bold 9700

Re: [BB10] Title bar is not displayed

haha you're too kind ;-)

and it will definitely inspire you -- I started out a few months ago -- coming from AIR it's been pretty sweet. Best of luck to you!
J. Rab (Blog) (Twitter)
--
1. If you liked my post or found it useful please click on the thumbs up and provide a Like!
2. If my post solved your problem please click on the Accept as Solution button. Much appreciated!

Approved Apps: OnTrack | ssShots | Hangman
Highlighted
Developer
Posts: 232
Registered: ‎01-30-2011
My Device: Dev Alpha C, Z10 LE
My Carrier: P4

Re: [BB10] Title bar is not displayed


JRab wrote:
haha you're too kind ;-)

and it will definitely inspire you -- I started out a few months ago -- coming from AIR it's been pretty sweet. Best of luck to you!


Thanks again. I started last week, from AIR too Smiley Happy
(From AIR forum I know Your helpfulness Smiley Happy )

 

All time online Smiley Very Happy