public static void Attach(Frame frame)
{
if (frame == null)
throw new ArgumentNullException("frame");
if (frame != attachedFrame)
{
if (attachedFrame != null)
attachedFrame.Navigated -= FrameNavigated;
frame.Navigated += FrameNavigated;
attachedFrame = frame;
}
var content = frame.Content;
if (content != null)
TrackFrameNavigate(content.GetType());
}