private void SetRichElementsState() { // if tombstoning - don't overwrite any selected photo from user with the one from DB. if (photoData == null) { task.PreviewPhoto(PhotoPreviewElement); } SetPhotoPreviewState(); SetVoiceMemoPreviewState(); }
protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e) { base.OnNavigatedTo(e); InitTask(); DataContext = task; task.PreviewPhoto(PhotoPreview); (ApplicationBar.Buttons[0] as ApplicationBarIconButton).IsEnabled = !task.IsCompleted; }