How to correctly handle application deactivation and reactivation

Much has been written about tombstoning and how important it is that your application be able to save and restore state once it goes into the background. This is all good. One of the finer points of the Windows Phone application model that has received less attention is the case where your application moves into…