//string title = string.Empty; //public string Title //{ // get { return title; } // set { SetProperty(ref title, value); } //} //protected bool SetProperty<T>(ref T backingStore, T value, // [CallerMemberName]string propertyName = "", // Action onChanged = null) //{ // if (EqualityComparer<T>.Default.Equals(backingStore, value)) // return false; // backingStore = value; // onChanged?.Invoke(); // OnPropertyChanged(propertyName); // return true; //} public BaseViewModel() { DialogService = ViewModelInjector.Resolve <IDialogService>(); NavigationService = ViewModelInjector.Resolve <INavigationService>(); // var settingsService = ViewModelInjector.Resolve<ISettingsService>(); // GlobalSetting.Instance.BaseIdentityEndpoint = settingsService.IdentityEndpointBase; // GlobalSetting.Instance.BaseGatewayShoppingEndpoint = settingsService.GatewayShoppingEndpointBase; // GlobalSetting.Instance.BaseGatewayMarketingEndpoint = settingsService.GatewayMarketingEndpointBase; }
/// <summary> /// Creates new NavigatonService object in DI container, and returns a reference to it, /// before invoking InitializeAsync() /// </summary> private Task InitNavigation() { var navigationService = ViewModelInjector.Resolve <INavigationService>(); return(navigationService.InitializeAsync()); }
private void InitApp() { _settingsService = ViewModelInjector.Resolve <ISettingsService>(); //if (!_settingsService.UseMocks) //ViewModelLocator.UpdateDependencies(_settingsService.UseMocks); }