Quantcast
Channel: MVVM Light Toolkit
Viewing all articles
Browse latest Browse all 1826

New Post: Ghost view instances

$
0
0

I'm just trying to figure out something right now related to the wp7/8 navigation.  Say you have an article reader app that has a listing of articles page and a page that shows the article when you click one.  When an article is clicked, a new page is instantiated using a viewModel from the locator as its data context. When you click back, the view gets "destroyed", but the vm stays intact?  When a user clicks another article, the process repeats.  

My question is concerning those old views.  Do the viewModels make a strong link to the views when properties are bound, and if so, how do you get around that.  I'm trying to eliminate any potential memory leaks before they occur.  When the view is destroyed, does that take care of the property changed events that were subscribed to?


Viewing all articles
Browse latest Browse all 1826

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>