/// <summary> /// Will connect the fields to the views of the layout. /// </summary> private void setupViews() { _progBar = FindViewById <ProgressBar>(Resource.Id.MainProgressBar); _menuButton = FindViewById <ImageView>(Resource.Id.MainMenuIcon); _settingsButton = FindViewById <ImageView>(Resource.Id.MainMenuSettings); _searchField = FindViewById <MainEditText>(Resource.Id.MainEditText); _listView = FindViewById <ListView>(Resource.Id.MainListView); _progBar.Visibility = ViewStates.Invisible; }
/// <summary> /// Will connect the UI fields with the controls of the layout. /// </summary> private void setupViews() { _progBar = FindViewById <ProgressBar>(Resource.Id.LoginProgressBar); _description = FindViewById <MainTextView>(Resource.Id.LoginDescription); _username = FindViewById <MainEditText>(Resource.Id.LoginUsername); _password = FindViewById <MainEditText>(Resource.Id.LoginPassword); _loginButton = FindViewById <Button>(Resource.Id.LoginButton); _loginButton.Typeface = Typeface.CreateFromAsset(Assets, "fonts/segoeui.ttf"); _registerText = FindViewById <MainTextView>(Resource.Id.LoginRegisterText); _progBar.Visibility = ViewStates.Invisible; }
/// <summary> /// Connects the UI controls to the fields of this activity. /// </summary> private void setupViews() { _progBar = FindViewById <ProgressBar>(Resource.Id.ServingProgressBar); _name = FindViewById <MainTextView>(Resource.Id.ServingFoodName); _description = FindViewById <MainTextView>(Resource.Id.ServingDescription); _servingPresetDescription = FindViewById <MainTextView>(Resource.Id.ServingPresetDescription); _servingCustomDescription = FindViewById <MainTextView>(Resource.Id.ServingCustomDescription); _listView = FindViewById <ListView>(Resource.Id.ServingListView); _customServing = FindViewById <MainEditText>(Resource.Id.ServingCustomEditText); _servingUnit = FindViewById <MainTextView>(Resource.Id.ServingCustomUnit); _addButton = FindViewById <Button>(Resource.Id.ServingAddButton); _addButton.Typeface = Typeface.CreateFromAsset(Assets, "fonts/segoeui.ttf"); _progBar.Visibility = ViewStates.Invisible; }
/// <summary> /// Will connect the controls to the fields of this class. /// </summary> private void setupViews() { _editText = FindViewById <MainEditText>(Resource.Id.NameEditText); _charsLeft = FindViewById <MainTextView>(Resource.Id.NameCharsLeft); _nameDescription = FindViewById <MainTextView>(Resource.Id.SetNameDescription); _saveButton = FindViewById <Button>(Resource.Id.SetNameSaveButton); _nameDescription.Text = Localization.Static.Raw(ResourceKeyNames.Static.NameDescription); _saveButton.Text = Localization.Static.Raw(ResourceKeyNames.Static.Save); _editText.Text = ""; _charsLeft.Text = ""; _saveButton.Enabled = false; }
/// <summary> /// Will connect the views to the local fields of this class. /// </summary> private void setupViews() { _progBar = FindViewById <ProgressBar>(Resource.Id.ComposeProgressBar); _charsLeft = FindViewById <MainTextView>(Resource.Id.ComposeCharsLeft); _composer = FindViewById <MainTextView>(Resource.Id.ComposeComposer); _editText = FindViewById <MainEditText>(Resource.Id.ComposeEditText); _submitButton = FindViewById <Button>(Resource.Id.ComposeSubmitButton); _progBar.Visibility = ViewStates.Invisible; _charsLeft.Text = _maxLength.ToString(); _composer.Text = DBManager.Static.DBAccessor.Select <SimpleItem>()[0].Value; _composer.MakeBold(); _editText.ChangeFontSize(19); _submitButton.Text = Localization.Static.Raw(ResourceKeyNames.Static.Submit); _submitButton.Enabled = false; }
/// <summary> /// Will connect the fields to the views of the layout. /// </summary> private void setupViews() { _progBar = FindViewById <ProgressBar>(Resource.Id.SettingsProgressBar); _title = FindViewById <MainTextView>(Resource.Id.SettingsTitle); _dailyKcalDescription = FindViewById <MainTextView>(Resource.Id.SettingsDailyKcalDescription); _kcalEdit = FindViewById <MainEditText>(Resource.Id.SettingsDailyKcal); _saveButton = FindViewById <Button>(Resource.Id.SettingsSaveButton); _loggedInAs = FindViewById <MainTextView>(Resource.Id.SettingsLoggedInAs); _logoutButton = FindViewById <Button>(Resource.Id.SettingsLogoutButton); _versionNumber = FindViewById <MainTextView>(Resource.Id.SettingsVersionInfo); _versionNumber.Text = getVersionNumber(); _contact = FindViewById <MainTextView>(Resource.Id.SettingsContact); _contact.MakeBold(); _progBar.Visibility = Android.Views.ViewStates.Invisible; var buttonTypeFace = Typeface.CreateFromAsset(Assets, "fonts/segoeui.ttf"); _saveButton.Typeface = buttonTypeFace; _logoutButton.Typeface = buttonTypeFace; }