public void ContinueToProduct(ProductViewModel product) { if (ProductViewModel == null) { ProductViewModel = new ProductViewModel(); } ProductViewModel.Initialize(product); // Note that we update the existing ProductViewModel instance instead of replacing it with a new instance, because views may exist that are bound to the existing instance. RunOnUIThread(() => _navigator.NavigateToProductView()); }
public void ContinueToProduct(ProductViewModel product, bool skipNavigation = false) { if (ProductViewModel == null) { ProductViewModel = new ProductViewModel(); } ProductViewModel.Initialize(product); // Note that we update the existing ProductViewModel instance instead of replacing it with a new instance, because views may exist that are bound to the existing instance. if (!skipNavigation) { RunOnUIThread(() => _navigator.NavigateToProductView(CurrentNavigationContext)); } }