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: 134
Registered: ‎02-24-2013
My Device: BlackBerry Z10 LE
My Carrier: Telcel

How to transfer my application to background?

[ Edited ]

Hi, Friends.

I have an application which waits 10 seconds to vibrate and display an image of terror and scare the victim.

The problem is that I want to make click on the button "hide", the application will send to the background.

So far I have not found information about it

Regards!

Highlighted
Developer
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: How to transfer my application to background?

There is currently no API to let an app either hide itself, or more importantly for your use case, to make itself reappear as the fullscreen app.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Developer
Posts: 323
Registered: ‎05-07-2009
My Device: BlackBerry Z10, PlayBook, 9900
My Carrier: Telus

Re: How to transfer my application to background?

I haven't tested it, but would the Application.minimize() method handle what you want?

 

http://developer.blackberry.com/cascades/reference/bb__application.html#function-minimize

 

Button {

    text: "Shrink Me!"
    onClicked: {
         Application.minimize();
    }
}

PlayBook Apps: DataMine, Dots + Boxes, 5 Marbles
BlackBerry SmartPhone Apps: 5 Marbles Soon: **** (D.Z.A), ****Quest, **** Challenge, VaultCracker, DevBrowser, Radial****
Developer
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: How to transfer my application to background?

Hey steve_web, you're right about that! I forgot that one...

However, it doesn't *hide* the app (which he might have wanted), and in any case there's still no way to get the app back to being fullscreen, programmatically, for his use case.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!