C# Class PhotoSharingApp.Universal.Facades.NavigationFacade

Encapsulates page navigation.
Inheritance: INavigationFacade
Afficher le fichier Open project: Microsoft/Appsample-Photosharing

Méthodes publiques

Méthode Description
AddType ( Type view, Type viewModel ) : void

Adds the specified types to the association list.

GoBack ( int steps = 1 ) : void

Goes back in the navigation stack for the specified number of steps.

NavigateToAboutView ( ) : void

Navigates to the about view.

NavigateToCameraView ( ) : void

Navigates to the camera view.

NavigateToCameraView ( CategoryPreview category ) : void

Navigates to the camera view.

NavigateToCategoriesView ( ) : void

Navigates to the categories view.

NavigateToCropView ( StorageFile file ) : void

Navigates to the crop view.

NavigateToCropView ( StorageFile file, CategoryPreview category ) : void

Navigates to the crop view.

NavigateToPhotoDetailsView ( CategoryPreview category, Photo photo ) : void

Navigates to the photo details view.

NavigateToPhotoDetailsView ( Photo photo ) : void

Navigates to the photo details view.

NavigateToPhotoDetailsView ( string photoId ) : void

Navigates to the photo details view.

NavigateToPhotoStream ( Category category ) : void

Navigates to the photo stream view.

NavigateToPhotoStream ( CategoryPreview category ) : void

Navigates to the photo stream view.

NavigateToPhotoStream ( CategoryPreview categoryPreview, PhotoThumbnail photoThumbnail ) : void

Navigates to the photo stream view.

NavigateToProfileView ( ) : void

Navigates to the signed-in user's profile view.

NavigateToProfileView ( User user ) : void

Navigates to the given user's profile view.

NavigateToSignInView ( ) : void

Navigates to the sign-in view.

NavigateToUploadView ( Photo photo, Category category ) : void

Navigates to the upload view to update data of the existing photo.

NavigateToUploadView ( WriteableBitmap image, CategoryPreview category ) : void

Navigates to the upload view.

NavigateToWelcomeView ( ) : void

Navigates to the Welcome View page.

RemoveBackStackFrames ( int numberOfFrames ) : void

Displays a dialog that lets the user pick a category. Removes the specified number of frames from the back stack.

RemoveUploadPhotoFramesFromBackStack ( string categoryIdNavigatedTo ) : void

Removes the frames associated with uploading a photo from the back stack.

ShowCategoryChooserDialog ( ) : Task

Displays a dialog that lets the user pick a category.

ShowCreateCategoryDialog ( ) : System.Threading.Tasks.Task

Displays a dialog that lets the user create a new category.

ShowGiveGoldDialog ( Photo photo ) : Task

Displays a dialog that lets the user give gold

Private Methods

Méthode Description
EnsureNavigationFrameIsAvailable ( ) : void

Makes sure a frame is available that can be used for navigation.

IsTypePhotoUploadRelated ( Type pageType ) : bool

Checks if the specified type is a photo upload related page.

Navigate ( Type viewModelType, object parameter = null, bool serializeParameter = true ) : void

Navigates to the specified view model type.

Method Details

AddType() public static méthode

Adds the specified types to the association list.
The ViewModel has already been added and is only allowed once.
public static AddType ( Type view, Type viewModel ) : void
view System.Type The view type.
viewModel System.Type The ViewModel type.
Résultat void

GoBack() public méthode

Goes back in the navigation stack for the specified number of steps.
public GoBack ( int steps = 1 ) : void
steps int The steps. By default: 1.
Résultat void

NavigateToAboutView() public méthode

Navigates to the about view.
public NavigateToAboutView ( ) : void
Résultat void

NavigateToCameraView() public méthode

Navigates to the camera view.
public NavigateToCameraView ( ) : void
Résultat void

NavigateToCameraView() public méthode

Navigates to the camera view.
public NavigateToCameraView ( CategoryPreview category ) : void
category PhotoSharingApp.Universal.Models.CategoryPreview The category.
Résultat void

NavigateToCategoriesView() public méthode

Navigates to the categories view.
public NavigateToCategoriesView ( ) : void
Résultat void

NavigateToCropView() public méthode

Navigates to the crop view.
public NavigateToCropView ( StorageFile file ) : void
file Windows.Storage.StorageFile The photo to crop.
Résultat void

NavigateToCropView() public méthode

Navigates to the crop view.
public NavigateToCropView ( StorageFile file, CategoryPreview category ) : void
file Windows.Storage.StorageFile The photo to crop.
category PhotoSharingApp.Universal.Models.CategoryPreview The selected category for the photo.
Résultat void

NavigateToPhotoDetailsView() public méthode

Navigates to the photo details view.
public NavigateToPhotoDetailsView ( CategoryPreview category, Photo photo ) : void
category PhotoSharingApp.Universal.Models.CategoryPreview The category.
photo PhotoSharingApp.Universal.Models.Photo The photo.
Résultat void

NavigateToPhotoDetailsView() public méthode

Navigates to the photo details view.
public NavigateToPhotoDetailsView ( Photo photo ) : void
photo PhotoSharingApp.Universal.Models.Photo The photo.
Résultat void

NavigateToPhotoDetailsView() public méthode

Navigates to the photo details view.
public NavigateToPhotoDetailsView ( string photoId ) : void
photoId string The photoId of the photo to navigate to.
Résultat void

NavigateToPhotoStream() public méthode

Navigates to the photo stream view.
public NavigateToPhotoStream ( Category category ) : void
category PhotoSharingApp.Universal.Models.Category The category.
Résultat void

NavigateToPhotoStream() public méthode

Navigates to the photo stream view.
public NavigateToPhotoStream ( CategoryPreview category ) : void
category PhotoSharingApp.Universal.Models.CategoryPreview The category preview instance.
Résultat void

NavigateToPhotoStream() public méthode

Navigates to the photo stream view.
public NavigateToPhotoStream ( CategoryPreview categoryPreview, PhotoThumbnail photoThumbnail ) : void
categoryPreview PhotoSharingApp.Universal.Models.CategoryPreview The category preview instance.
photoThumbnail PhotoSharingApp.Universal.Models.PhotoThumbnail /// The photo thumbnail that will determine the scroll position. ///
Résultat void

NavigateToProfileView() public méthode

Navigates to the signed-in user's profile view.
public NavigateToProfileView ( ) : void
Résultat void

NavigateToProfileView() public méthode

Navigates to the given user's profile view.
public NavigateToProfileView ( User user ) : void
user PhotoSharingApp.Universal.Models.User The user to show the profile view for.
Résultat void

NavigateToSignInView() public méthode

Navigates to the sign-in view.
public NavigateToSignInView ( ) : void
Résultat void

NavigateToUploadView() public méthode

Navigates to the upload view to update data of the existing photo.
public NavigateToUploadView ( Photo photo, Category category ) : void
photo PhotoSharingApp.Universal.Models.Photo The photo to update.
category PhotoSharingApp.Universal.Models.Category The associated category.
Résultat void

NavigateToUploadView() public méthode

Navigates to the upload view.
public NavigateToUploadView ( WriteableBitmap image, CategoryPreview category ) : void
image Windows.UI.Xaml.Media.Imaging.WriteableBitmap The image to upload.
category PhotoSharingApp.Universal.Models.CategoryPreview The category to upload the image into.
Résultat void

NavigateToWelcomeView() public méthode

Navigates to the Welcome View page.
public NavigateToWelcomeView ( ) : void
Résultat void

RemoveBackStackFrames() public méthode

Displays a dialog that lets the user pick a category. Removes the specified number of frames from the back stack.
public RemoveBackStackFrames ( int numberOfFrames ) : void
numberOfFrames int The number of frames.
Résultat void

RemoveUploadPhotoFramesFromBackStack() public méthode

Removes the frames associated with uploading a photo from the back stack.
public RemoveUploadPhotoFramesFromBackStack ( string categoryIdNavigatedTo ) : void
categoryIdNavigatedTo string The category id that was navigated to after photo upload.
Résultat void

ShowCategoryChooserDialog() public méthode

Displays a dialog that lets the user pick a category.
public ShowCategoryChooserDialog ( ) : Task
Résultat Task

ShowCreateCategoryDialog() public méthode

Displays a dialog that lets the user create a new category.
public ShowCreateCategoryDialog ( ) : System.Threading.Tasks.Task
Résultat System.Threading.Tasks.Task

ShowGiveGoldDialog() public méthode

Displays a dialog that lets the user give gold
public ShowGiveGoldDialog ( Photo photo ) : Task
photo PhotoSharingApp.Universal.Models.Photo
Résultat Task