public MainPage() { this.InitializeComponent(); this.NavigationCacheMode = NavigationCacheMode.Required; Current = this; // gán static resouce bên mainpage.xaml để xài _imageViewModel = Resources["imageDataContext"] as ImageRecognizeViewModel; //listpickerflyout.ItemsSource = Util.AvailableCountries.Values; //int language = Convert.ToInt32(LocalSettingHelper.GetLocalSettingValue(LocalSettingHelper.RecogLanguageKey)); //settingbtn.Content = Enum.Parse (typeof(OcrLanguage),LocalSettingHelper.GetLocalSettingValue(LocalSettingHelper.RecogLanguageKey).ToString()); _imageViewModel.Language = (OcrLanguage) Enum.Parse( typeof(OcrLanguage), LocalSettingHelper.GetLocalSettingValue(LocalSettingHelper.RecogLanguageKey).ToString()); }
public MainPage() { this.InitializeComponent(); this.NavigationCacheMode = NavigationCacheMode.Required; Current = this; // gán static resouce bên mainpage.xaml để xài _imageViewModel = Resources["imageDataContext"] as ImageRecognizeViewModel; //listpickerflyout.ItemsSource = Util.AvailableCountries.Values; //int language = Convert.ToInt32(LocalSettingHelper.GetLocalSettingValue(LocalSettingHelper.RecogLanguageKey)); //settingbtn.Content = Enum.Parse (typeof(OcrLanguage),LocalSettingHelper.GetLocalSettingValue(LocalSettingHelper.RecogLanguageKey).ToString()); _imageViewModel.Language = (OcrLanguage)Enum.Parse( typeof(OcrLanguage), LocalSettingHelper.GetLocalSettingValue(LocalSettingHelper.RecogLanguageKey).ToString()); }
public ImageRecognizePage() { Current = this; this.InitializeComponent(); this.NavigationCacheMode = Windows.UI.Xaml.Navigation.NavigationCacheMode.Required; // gán static resouce bên xaml để xài _imageViewModel = Resources["imageDataContext"] as ImageRecognizeViewModel; listpickerflyout.ItemsSource = Util.AvailableCountries.Values; _imageViewModel.Language = (OcrLanguage)Enum.Parse( typeof(OcrLanguage), LocalSettingHelper.GetLocalSettingValue(LocalSettingHelper.RecogLanguageKey).ToString()); HardwareButtons.BackPressed += hardwareButtons_BackPressed; }
public ImageRecognizePage() { Current = this; this.InitializeComponent(); this.NavigationCacheMode = Windows.UI.Xaml.Navigation.NavigationCacheMode.Required; // gán static resouce bên xaml để xài _imageViewModel = Resources["imageDataContext"] as ImageRecognizeViewModel; listpickerflyout.ItemsSource = Util.AvailableCountries.Values; _imageViewModel.Language = (OcrLanguage)Enum.Parse( typeof(OcrLanguage), LocalSettingHelper.GetLocalSettingValue(LocalSettingHelper.RecogLanguageKey).ToString()); HardwareButtons.BackPressed += hardwareButtons_BackPressed; }