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


Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.


Reply
Developer
Developer
Posts: 46
Registered: ‎02-22-2012
My Device: Developer
My Carrier: Various

More Signal/Slots grief + SystemDialog

 

4 hrs later....

 

Given the content at end of thread:

 

http://supportforums.blackberry.com/t5/Cascades-Development/SystemPrompt-Signals-and-Slots-No-Such-S...

 

perhaps someone from BB can fix the 'documentation' at

 

https://developer.blackberry.com/cascades/documentation/ui/dialogs_toasts/sysdialogs.html#pat1340376...

 

so the exaple code might actually work.

 

In particular the C++ code as copied below on the page is just wrong.

 

void App::showDialog() {
 
    // Set up the dialog with a title, some body text, 
    // and an custom button. Don't forget to set it to
    // dismiss the dialog automatically.
 
    // Label the two standard buttons with specific text.
    // Add a custom button for more stuff.
    dialog = new SystemDialog("I accept", "More stuff", "I decline");
    dialog->setTitle("My Dialog Title");
    dialog->setBody("This is the body of my dialog. " +
         "I can put valuable information in here.");
    
    // Connect your functions to handle the predefined signals for the buttons.
    // The slot will check the SystemUiResult to see which button was clicked. 
 
    bool success = QObject::connect(dialog,
            SIGNAL (finished(bb::system:Smiley FrustratedystemUiResult::Type value))
            this,
            SLOT (onDialogFinished()));
 
    Q_ASSERT(success);
    // Indicate that the variable success isn't used in the rest of the app,
    // to prevent a compiler warning
    Q_UNUSED(success);
 
    // Now show the dialog in your UI
 
    dialog->show();
}