void Init() { ImageButton backButton = FindViewById <ImageButton>(Resource.Id.arrow_back_about); backButton.ContentDescription = ViewModels.SettingsViewModel.BACK_BUTTON_ACCESSIBILITY_TEXT; TextView titleField = FindViewById <TextView>(Resource.Id.settings_about_title); TextView textField = FindViewById <TextView>(Resource.Id.settings_about_text); TextView hiddenLink = FindViewById <TextView>(Resource.Id.settings_about_link); FindViewById <TextView>(Resource.Id.settings_about_version_info_textview).Text = ViewModels.SettingsPage5ViewModel.GetVersionInfo(); titleField.Text = SettingsPage5ViewModel.SETTINGS_PAGE_5_HEADER; titleField.SetAccessibilityDelegate(AccessibilityUtils.GetHeadingAccessibilityDelegate()); textField.Text = SettingsPage5ViewModel.SETTINGS_PAGE_5_CONTENT + $"\n {SettingsPage5ViewModel.SETTINGS_PAGE_5_LINK}"; textField.TextAlignment = TextAlignment.ViewStart; backButton.Click += new SingleClick((sender, args) => Finish()).Run; hiddenLink.Text = SettingsPage5ViewModel.SETTINGS_PAGE_5_LINK; LinkUtil.LinkifyTextView(hiddenLink); TextView accessibilityStatementLink = FindViewById <TextView>(Resource.Id.accessibility_statement_btn); accessibilityStatementLink.TextFormatted = HtmlCompat.FromHtml($"<a href=\"{SettingsPage5ViewModel.SETTINGS_PAGE_5_ACCESSIBILITY_STATEMENT_BUTTON_URL}\">{SettingsPage5ViewModel.SETTINGS_PAGE_5_ACCESSIBILITY_STATEMENT_BUTTON_TEXT}</a>", HtmlCompat.FromHtmlModeLegacy); accessibilityStatementLink.MovementMethod = new Android.Text.Method.LinkMovementMethod(); View rootView = Window.DecorView.RootView; rootView.LayoutDirection = LayoutUtils.GetLayoutDirection(); backButton.SetBackgroundResource(LayoutUtils.GetBackArrow()); }
void Init() { ImageButton backButton = FindViewById <ImageButton>(Resource.Id.arrow_back); backButton.ContentDescription = SettingsViewModel.BACK_BUTTON_ACCESSIBILITY_TEXT; TextView titleField = FindViewById <TextView>(Resource.Id.settings_how_it_works_title); TextView intro = FindViewById <TextView>(Resource.Id.settings_how_it_works_intro); TextView heading1 = FindViewById <TextView>(Resource.Id.settings_how_it_works_heading1); TextView paragraph1textView1 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph1textView1); TextView paragraph1textView2 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph1textView2); TextView heading2 = FindViewById <TextView>(Resource.Id.settings_how_it_works_heading2); TextView paragraph2textView1 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph2textView1); TextView paragraph2textView2 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph2textView2); TextView paragraph2textView3 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph2textView3); TextView paragraph2textView4 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph2textView4); TextView heading3 = FindViewById <TextView>(Resource.Id.settings_how_it_works_heading3); TextView paragraph3textView1 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph3textView1); TextView heading4 = FindViewById <TextView>(Resource.Id.settings_how_it_works_heading4); TextView paragraph4textView1 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph4textView1); TextView paragraph4textView2 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph4textView2); TextView paragraph4textView3 = FindViewById <TextView>(Resource.Id.settings_how_it_works_paragraph4textView3); titleField.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_HEADER; intro.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_INTRO; heading1.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_1_TITLE; paragraph1textView1.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_1_CONTENT; paragraph1textView2.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_1_CONTENT2; heading2.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_2_TITLE; paragraph2textView1.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_2_CONTENT; paragraph2textView2.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_2_CONTENT2; paragraph2textView3.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_2_CONTENT3; paragraph2textView4.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_2_CONTENT4; heading3.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_3_TITLE; paragraph3textView1.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_3_CONTENT; heading4.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_4_TITLE; paragraph4textView1.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_4_CONTENT; paragraph4textView2.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_4_CONTENT2; paragraph4textView3.TextFormatted = HtmlCompat.FromHtml(SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT_TEXT_PARAGRAPH_4_CONTENT3, HtmlCompat.FromHtmlModeLegacy); titleField.SetAccessibilityDelegate(AccessibilityUtils.GetHeadingAccessibilityDelegate()); LinkUtil.LinkifyTextView(paragraph4textView3); FormatLink(paragraph4textView3); backButton.Click += new SingleClick((sender, args) => Finish()).Run; View rootView = Window.DecorView.RootView; rootView.LayoutDirection = LayoutUtils.GetLayoutDirection(); backButton.SetBackgroundResource(LayoutUtils.GetBackArrow()); }
void Init() { ImageButton backButton = FindViewById <ImageButton>(Resource.Id.arrow_back); backButton.ContentDescription = SettingsViewModel.SETTINGS_CHILD_PAGE_ACCESSIBILITY_BACK_BUTTON; TextView textField = FindViewById <TextView>(Resource.Id.settings_how_it_works_text); TextView titleField = FindViewById <TextView>(Resource.Id.settings_how_it_works_title); titleField.Text = SettingsPage2ViewModel.SETTINGS_PAGE_2_HEADER; textField.TextFormatted = HtmlCompat.FromHtml(SettingsPage2ViewModel.SETTINGS_PAGE_2_CONTENT, HtmlCompat.FromHtmlModeLegacy); LinkUtil.LinkifyTextView(textField); FormatLink(textField); backButton.Click += new SingleClick((sender, args) => Finish()).Run; }
void Init() { Button backButton = FindViewById <Button>(Resource.Id.arrow_back_help); backButton.ContentDescription = ViewModels.SettingsViewModel.SETTINGS_CHILD_PAGE_ACCESSIBILITY_BACK_BUTTON; TextView textField = FindViewById <TextView>(Resource.Id.settings_help_text); TextView titleField = FindViewById <TextView>(Resource.Id.settings_help_title); TextView hiddenLink = FindViewById <TextView>(Resource.Id.settings_help_link); titleField.Text = HEADER; textField.TextFormatted = HtmlCompat.FromHtml($"{CONTENT_TEXT_BEFORE_SUPPORT_LINK} <a href=\"https://{SUPPORT_LINK}\">{SUPPORT_LINK_SHOWN_TEXT}</a><br><br>" /* Note: * This functionality is not planned for release 1.0. Kept for future use. * //$"{EMAIL_TEXT} <a href=\"mailto:{EMAIL}\">{EMAIL}</a> {PHONE_NUM_Text} <a href=\"tel:{PHONE_NUM}\">{PHONE_NUM}</a>.<br><br>" + * //$"{PHONE_OPEN_TEXT}<br><br>" + * //$"{PHONE_OPEN_MON_THU}<br>" + * //$"{PHONE_OPEN_FRE}<br><br>" + * //$"{PHONE_OPEN_SAT_SUN_HOLY}" */ , HtmlCompat.FromHtmlModeLegacy); textField.ContentDescriptionFormatted = HtmlCompat.FromHtml($"{CONTENT_TEXT_BEFORE_SUPPORT_LINK} <a href=\"https://{SUPPORT_LINK}\">{SUPPORT_LINK_SHOWN_TEXT}</a><br><br>" /* Note: * This functionality is not planned for release 1.0. Kept for future use. * //$"{EMAIL_TEXT} <a href=\"mailto:{EMAIL}\">{EMAIL}</a> {PHONE_NUM_Text} <a href=\"tel:{PHONE_NUM}\">{PHONE_NUM_ACCESSIBILITY}</a>.<br><br>" + * //$"{PHONE_OPEN_TEXT}<br><br>" + * //$"{PHONE_OPEN_MON_THU_ACCESSIBILITY}<br>" + * //$"{PHONE_OPEN_FRE_ACCESSIBILITY}<br><br>" + * //$"{PHONE_OPEN_SAT_SUN_HOLY}" */ , HtmlCompat.FromHtmlModeLegacy); textField.MovementMethod = LinkMovementMethod.Instance; backButton.Click += new SingleClick((sender, args) => Finish()).Run; hiddenLink.Text = SUPPORT_LINK; hiddenLink.ContentDescription = SUPPORT_LINK_SHOWN_TEXT; LinkUtil.LinkifyTextView(hiddenLink); }
void Init() { ImageButton backButton = FindViewById <ImageButton>(Resource.Id.arrow_back_about); backButton.ContentDescription = ViewModels.SettingsViewModel.SETTINGS_CHILD_PAGE_ACCESSIBILITY_BACK_BUTTON; TextView titleField = FindViewById <TextView>(Resource.Id.settings_about_title); TextView textField = FindViewById <TextView>(Resource.Id.settings_about_text); TextView hiddenLink = FindViewById <TextView>(Resource.Id.settings_about_link); FindViewById <TextView>(Resource.Id.settings_about_version_info_textview).Text = ViewModels.SettingsPage5ViewModel.GetVersionInfo(); titleField.Text = SettingsPage5ViewModel.SETTINGS_PAGE_5_HEADER; textField.Text = SettingsPage5ViewModel.SETTINGS_PAGE_5_CONTENT + $" {SettingsPage5ViewModel.SETTINGS_PAGE_5_LINK}"; backButton.Click += new SingleClick((sender, args) => Finish()).Run; hiddenLink.Text = SettingsPage5ViewModel.SETTINGS_PAGE_5_LINK; LinkUtil.LinkifyTextView(hiddenLink); }