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
bbj
Contributor
bbj
Posts: 43
Registered: ‎02-22-2012
My Device: Developer
My Carrier: Various
Accepted Solution

Sheet opened and closed signals dont appear to be working

Any clues as to what special magical qml/qt/cascades thing you have to do to get the Sheet opened and closed signals to be delivered ?

 

Basic code fragment is

 

        Sheet* sheet=iNewSheet->Construct();
        bool ok=connect(sheet,SIGNAL(closed()),this,SLOT(onSheetClosed()));
        Q_ASSERT(ok);
        ok=connect(sheet,SIGNAL(opened()),this,SLOT(onSheetOpened()));
        Q_ASSERT(ok);
        sheet->open();

Both the connects appear to work - as in there is no assert.

The sheet is opened ok, but no signal gets delivered

The sheet can be closed ok, but no closed signal gets delivered.

We also tried the openedChanged() signal, but that does not seem to be delivered either

 

 

Please use plain text.
Developer
bcs925
Posts: 262
Registered: ‎07-13-2012
My Device: PlayBook, DA B, DA C, LE Z10 #102, Q10, Z30
My Carrier: T-Mobile

Re: Sheet opened and closed signals dont appear to be working

I use QML for sheets and the open/close signals work fine, for example:

 

                Button {
                    id: button1
                    text: "Game Info"
                    onClicked: gameInfo.open();
                    }

 

Sheet {
    id: gameInfo
    Page {
        Container {
... Button { text: "Menu" onClicked: gameInfo.close(); } }
... } }

 

---
Check out my BB10 Cascades Coding site: BBcascades.com & Cascades Blog: bbcascadescode.tumblr.com

My Built for BlackBerry app: The Dive Plan
Please use plain text.
bbj
Contributor
bbj
Posts: 43
Registered: ‎02-22-2012
My Device: Developer
My Carrier: Various

Re: Sheet opened and closed signals dont appear to be working

Dont believe what you have provided in qml is the same.

 

You are simply opening and closing the sheet - which works.

 

When the sheet open animation completes it is supposed to emit a signal to say the animation has completed.

When the sheet close animation completes its also supposed to emit a signal.

 

Its these opened and closed signals that dont appear to be working

Please use plain text.
Developer
bcs925
Posts: 262
Registered: ‎07-13-2012
My Device: PlayBook, DA B, DA C, LE Z10 #102, Q10, Z30
My Carrier: T-Mobile

Re: Sheet opened and closed signals dont appear to be working

Sorry mis understood your question. I'll look into the on animation completion signal next time I get a chance.
---
Check out my BB10 Cascades Coding site: BBcascades.com & Cascades Blog: bbcascadescode.tumblr.com

My Built for BlackBerry app: The Dive Plan
Please use plain text.
bbj
Contributor
bbj
Posts: 43
Registered: ‎02-22-2012
My Device: Developer
My Carrier: Various

Re: Sheet opened and closed signals dont appear to be working

If relevant to readers

 

No idea what weve changed but the

 

Sheet has finished animating + is now open and the

Sheet has finished animatng + is now fully closed

 

signals that didnt appear to work previously now work.

 

We can only guess its something to do with the 'connect' method parameters or perhaps the location of the mehod declarations or perhaps using 'Q_SLOTS' and not 'slots' declaration, or some other random Qt thing that does not get caught by either the pre-processor, the C compiler, the run time connect() return value or whatever other tools get applied to src to mangle it into Qt code.

 

What exactly is wrong with normal standard C++ interface inheritance for most of this ?

 

Please use plain text.