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
ekke
Posts: 1,509
Registered: ‎04-08-2010
My Device: Z10 (red Limited Edition), Q10, Z30
My Carrier: Telekom.de, O2, Vodafone

HowTo hide ActionBar after some time of Inactivity

The ActionBar has some visibility options: HIDE, OVERLAY, DEFAULT

But one is missing: HIDE automatically  if some time of inactivity

 

example: looking at an Image would be great to disappear the ActionBar and TitleBar and if user Touches on Screen, it reappears.

 

I have a Feature Request here:

https://www.blackberry.com/jira/browse/BBTEN-196

please vote for it if it makes sense for you, too

 

after discussing possible workarounds with Animations or QTimer at IssueTracker, Twitter and BBM,

I wrote a small sample for you to copy/paste some code from or to get the idea:

 

https://github.com/ekke/snippet-cascades-hide-actionbar

(here's a video demoing what's the output:

http://vimeo.com/ekkescorner/cascades-hide-actionbar )

 

Attention: there are 2 bugs related with this:

if changing the orientation on AlphaDevice twice withoput doing anything else, contetn will be scrambled:

https://www.blackberry.com/jira/browse/BBTEN-183

workaround: tap anywhere on the screen before switching Orientation

 

TitleBar on Landscape is too small:

https://www.blackberry.com/jira/browse/BBTEN-206

(Attention: as of writing this message this Issue isn't public yet - you have to wait for approvement by RIM)

 

have fun with my example HowTo hide ActionBar and TitleBar.

I have implemented it together with Orientation Support: only in Landscape Title and ActionBar will be hidden after 3000 ms

 

ekke

-------------------------------------------------------------------------------
ekke (independent software architect, rosenheim, germany)

BlackBerry Elite Developer
International Development Mobile Apps BlackBerry 10 Cascades
Cascades - Workshops / Trainings / Bootcamps

Open Source Enthusiast
blog: http://ekkes-corner.org videos: http://www.youtube.com/user/ekkescorner
bb10-development: http://appbus.org Twitter: @ekkescorner
Please use plain text.
BlackBerry Development Advisor (Retired)
mgoulet
Posts: 329
Registered: ‎05-07-2012
My Device: BB Alpha
My Carrier: N/A

Re: HowTo hide ActionBar after some time of Inactivity

ekke,

 

Thanks for your constructive post!

As you know, https://www.blackberry.com/jira/browse/BBTEN-196 has been addressed.

We will need to dig deeper for the other two and follow-up on the raised JIRAs.

 

Thanks,

 

Martin

 

 

 

Please use plain text.
Developer
jamiejulius
Posts: 49
Registered: ‎06-06-2012
My Device: Bold 9700
My Carrier: Pelephone

Re: HowTo hide ActionBar after some time of Inactivity

Hi,

 

Great suggestion, ekke.

 

I'm curious to know what is meant by "BBTEN-196 had been addressed". Should we be expecting this feature to be provided by RIM in a coming beta?

 

Thanks,

 

Jamie

Please use plain text.
Super Contributor
Meghasanghvi
Posts: 306
Registered: ‎08-10-2010
My Device: Not Specified

Re: HowTo hide ActionBar after some time of Inactivity

Hi,

 

You can hide ActionBar using following code.

 actionBarVisibility = ChromeVisibility.Hidden


For visibility of ActionBar you can use following code.

 actionBarVisibility = ChromeVisibility.Visible

 


To implement this on ImageView you can add code on Imageview onTouch event.

 

Thanks,

Megha.

 

Feel free to press like or accept as a solution.

 

 

Please use plain text.
Developer
jamiejulius
Posts: 49
Registered: ‎06-06-2012
My Device: Bold 9700
My Carrier: Pelephone

Re: HowTo hide ActionBar after some time of Inactivity

I believe that the feature request was to support a new mode whereby the bar will automatically hide itself after some time of inactivity.

Please use plain text.