Jul 30, 2011 at 12:18 PM
Edited Jul 30, 2011 at 12:40 PM
I'm having a really strange issue that I'm having trouble nailing down the exact cause of.
What I'm seeing is that I have a page (that is four pages into the navigation stack) that invokes a CameraCaptureTask using the new EventAggregator in 1.1. Once that task is complete I press the hardware back button two times, at this point I would expect
the application to be displaying the second page in the stack, however at that point that app crashes (with no exception) to the application list screen.
I've narrowed the line that causes this to the GC.Collect call in FrameAdapter.OnNavigated but I really have no idea why. Commenting out the Garbage Collection fixes the issues.
I've tried simplifying the code, removing the EventAggregator entirely and just invoking "new CameraCaptureTask().Show()" (and therefore skipping the handler code as well) still causes the same problem.
I'm truly perplexed by this one, it appears as if the entire application is being garbage collected. Why it's the second page back after the task I have no idea about sorry.
Edit: I've also found the replacing the CameraCaptureTask with PhotoChooserTask also prevents collection.