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
Regular Contributor
Posts: 54
Registered: ‎04-05-2013
My Device: Q10
My Carrier: T-Mobile

App becomes *partially* unresponsive for 30 seconds after a pushed navigation page is destroyed.

[ Edited ]

There is a really long pause after page.destroy(), when I press "back" and

destroy a pushed Navigation Page.

This page was used to load and show a ridiculously huge list.
The page, when it is destroyed, contains a lot of child QObjects in its model, objects that need to be destroyed. I suppose it is understandable that it takes some time to clean up...

During this time, my program is *partially* nonresponsive but it
does queue tap events in the ListView, responds to the swipe-to-scroll
up/down gestures, shows/hides the menus, and also let me change tabs.

However, I believe one of the main threads is blocked still.

This is because if I keep tapping on the listview (which responds to scrolls but not taps!!)

each tap event is queued, but no new page is created/pushed until delay has passed, so it APPEARS as if my tap didn't register at all.

 

Then, the device wakes up... and all of those tap events are consumed and lots of duplicate pages are created and pushed!

 

I want to avoid that.


After about 30 seconds (!), everything goes back to normal.

 

Is this garbage collection? Which thread handles this?

I normally expect duplicate tap events on my listview to be ignored after the first one is clicked, but I guess need to pop up something modal while this is happening.

 

What I want to know is, how do I know when this starts and ends? Is there a signal I can listen to?

It seems that page.destroy does its cleanup in a different thread? How do I know when that thread is no longer busy?