private TextView createHelperTextView() { var textView = new AppCompatTextView(Context); setTextViewTextColorFallbackColorWhenMissingStyleAttrs(textView); if (helperTextColor != null) { textView.SetTextColor(helperTextColor); } if (helperTextFontSize > 0) { textView.SetTextSize(ComplexUnitType.Px, helperTextFontSize); } return(textView); }
protected override void OnCreate(Bundle savedInstanceState) { base.OnCreate(savedInstanceState); UserCardHeader = FindViewById <AppCompatTextView>(Resource.Id.user_card_header); UserCardSubHeader = FindViewById <AppCompatTextView>(Resource.Id.user_cart_subtile); UserName = FindViewById <AppCompatEditText>(Resource.Id.user_name); UserEmail = FindViewById <AppCompatEditText>(Resource.Id.user_email); UserPhone = FindViewById <AppCompatEditText>(Resource.Id.user_phone); TelegramAccount = FindViewById <Spinner>(Resource.Id.spinnerJoinedTelegramAccount); UserAlarmSubscribing = FindViewById <Switch>(Resource.Id.user_alarms_switch); UserCommandsAllowed = FindViewById <Switch>(Resource.Id.user_commands_switch); UserFooterLayout = FindViewById <LinearLayout>(Resource.Id.user_footer_layout); UserCardButtonOk = FindViewById <AppCompatButton>(Resource.Id.user_button_ok); int user_id = Intent.Extras.GetInt(nameof(UserModel.Id), 0); List <TelegramUserModel> telegram_users = new List <TelegramUserModel>(); lock (DatabaseContext.DbLocker) { using (DatabaseContext db = new DatabaseContext(gs.DatabasePathBase)) { telegram_users = db.TelegramUsers.Where(x => x.LinkedUserId == null || x.LinkedUserId == user_id).ToList(); } } TelegramUsers = new Dictionary <int, string>() { { 0, "" } }; if (telegram_users != null && telegram_users.Count > 0) { telegram_users.ForEach(x => { TelegramUsers.Add(x.Id, x.ToString()); }); } ArrayAdapter <string> adapterUsers = new ArrayAdapter <string>(this, Android.Resource.Layout.SimpleSpinnerItem, TelegramUsers.Values.ToList()); adapterUsers.SetDropDownViewResource(Android.Resource.Layout.SimpleSpinnerDropDownItem); TelegramAccount.Adapter = adapterUsers; }
void UpdateToolbarSubtitle(CustomPage cPage, AppCompatTextView subTitleTextView, Typeface originalFont, ColorStateList defaultColorStateList) { ClearTextView(subTitleTextView, true); if (cPage.FormattedSubtitle != null && cPage.FormattedSubtitle.Spans.Count > 0) { subTitleTextView.TextFormatted = cPage.FormattedSubtitle.ToAttributed(Font.Default, Xamarin.Forms.Color.Default, _subTitleTextView); subTitleTextView.Visibility = ViewStates.Visible; } else if (!string.IsNullOrEmpty(cPage.Subtitle)) { UpdateToolbarTextColor(subTitleTextView, CustomNavigationPage.GetSubtitleColor(cPage), _originalColorStateList); UpdateToolbarTextFont(subTitleTextView, CustomNavigationPage.GetSubtitleFont(cPage), _originalFont); subTitleTextView.Text = cPage.Subtitle; subTitleTextView.Visibility = ViewStates.Visible; } }
protected override void OnCreate(Bundle savedInstanceState) { base.OnCreate(savedInstanceState); // Create your application here SetContentView(Resource.Layout.tv_show_detail); appBarLayout = FindViewById <AppBarLayout>(Resource.Id.image_toolbar_appbar_layout); collapseToolbar = FindViewById <CollapsingToolbarLayout>(Resource.Id.image_toolbar_collapsing_layout); collapseToolbar.TitleEnabled = true; detailToolbar = FindViewById <Toolbar>(Resource.Id.image_toolbar_main_toolbar); seasonsHeader = FindViewById <TabLayout>(Resource.Id.main_tabs_header); seasonEpisodesPager = FindViewById <ViewPager>(Resource.Id.main_tabs_viewpager); seasonsHeader.Visibility = ViewStates.Gone; seasonEpisodesPager.Visibility = ViewStates.Gone; detailImage = FindViewById <AppCompatImageView>(Resource.Id.image_toolbar_main_image); titleText = FindViewById <AppCompatTextView>(Resource.Id.image_toolbar_main_title); descriptionText = FindViewById <AppCompatTextView>(Resource.Id.image_toolbar_main_description); releaseText = FindViewById <AppCompatTextView>(Resource.Id.image_toolbar_main_release); genreText = FindViewById <AppCompatTextView>(Resource.Id.image_toolbar_main_genre); titleContainer = FindViewById <Android.Widget.LinearLayout>(Resource.Id.image_toolbar_collapsing_root); loadingView = FindViewById <ContentLoadingProgressBar>(Resource.Id.image_toolbar_loading); AppView.SetActionBarForActivity(detailToolbar, this); appBarLayout.OffsetChanged += AppLayout_OffsetChanged; // load data from link if (savedInstanceState is null) { var link = Intent.Extras.GetString("itemLink"); LoadData(link); } else { // get saved show data var show = Newtonsoft.Json.JsonConvert.DeserializeObject <SeriesDetails>(savedInstanceState.GetString(ShowDetailSaveInstanceName)); LoadData(null, show); } }
protected override void OnCreate(Bundle savedInstanceState) { base.OnCreate(savedInstanceState); HardwareCardHeader = FindViewById <AppCompatTextView>(Resource.Id.hardware_card_title); HardwareCardSubHeader = FindViewById <AppCompatTextView>(Resource.Id.hardware_card_subtitle); HardwareTopLayout = FindViewById <LinearLayout>(Resource.Id.hardware_top_layout); HardwareName = FindViewById <AppCompatEditText>(Resource.Id.hardware_name); HardwareAddress = FindViewById <AppCompatEditText>(Resource.Id.hardware_address); HardwarePassword = FindViewById <AppCompatEditText>(Resource.Id.hardware_password); HardwareAlarmSubscribing = FindViewById <Switch>(Resource.Id.hardware_alarms_switch); HardwareCommandsAllowed = FindViewById <Switch>(Resource.Id.hardware_commands_switch); HardwareFooterLayout = FindViewById <LinearLayout>(Resource.Id.hardware_footer_layout); HardwareCardButtonOk = FindViewById <AppCompatButton>(Resource.Id.hardware_button_ok); }
protected override void OnCreate(Bundle savedInstanceState) { base.OnCreate(savedInstanceState); lib = new TicTacToeLib(); currentBoard = lib.CreateEmptyBoard(); SetContentView(Resource.Layout.activity_main); Android.Support.V7.Widget.Toolbar toolbar = FindViewById <Android.Support.V7.Widget.Toolbar>(Resource.Id.toolbar); SetSupportActionBar(toolbar); tile1 = FindViewById <AppCompatTextView>(Resource.Id.textView1); tile2 = FindViewById <AppCompatTextView>(Resource.Id.textView2); tile3 = FindViewById <AppCompatTextView>(Resource.Id.textView3); tile4 = FindViewById <AppCompatTextView>(Resource.Id.textView4); tile5 = FindViewById <AppCompatTextView>(Resource.Id.textView5); tile6 = FindViewById <AppCompatTextView>(Resource.Id.textView6); tile7 = FindViewById <AppCompatTextView>(Resource.Id.textView7); tile8 = FindViewById <AppCompatTextView>(Resource.Id.textView8); tile9 = FindViewById <AppCompatTextView>(Resource.Id.textView9); tile1.SetOnTouchListener(this); tile2.SetOnTouchListener(this); tile3.SetOnTouchListener(this); tile4.SetOnTouchListener(this); tile5.SetOnTouchListener(this); tile6.SetOnTouchListener(this); tile7.SetOnTouchListener(this); tile8.SetOnTouchListener(this); tile9.SetOnTouchListener(this); FloatingActionButton fab = FindViewById <FloatingActionButton>(Resource.Id.fab); fab.Click += FabOnClick; reset_puzzle(); }
public void AddSearchToToolBar() { _toolBar.Title = "XamControls"; //Element.Title; //_toolBar.Menu.GetItem(0).SetIcon(); InitializeSearchView(); if (_toolBar?.GetChildAt(1) is AppCompatTextView) { actionMenuView = (Android.Support.V7.Widget.ActionMenuView)_toolBar?.GetChildAt(0); appCompatTextView = (AppCompatTextView)_toolBar?.GetChildAt(1); appCompatImageButton = (AppCompatImageButton)_toolBar?.GetChildAt(2); } else { actionMenuView = (Android.Support.V7.Widget.ActionMenuView)_toolBar?.GetChildAt(0); appCompatImageButton = (AppCompatImageButton)_toolBar?.GetChildAt(1); appCompatTextView = (AppCompatTextView)_toolBar?.GetChildAt(2); } }
protected override void OnCreate(Bundle savedInstanceState) { try { base.OnCreate(savedInstanceState); IMethods.IApp.FullScreenApp(this); // Set our view from the "Settings_MyAccount_Layout" layout resource SetContentView(Resource.Layout.Settings_MyAccount_Layout); //Set ToolBar var ToolBar = FindViewById <Toolbar>(Resource.Id.MyAccounttoolbar); ToolBar.Title = this.GetText(Resource.String.Lbl_My_Account); SetSupportActionBar(ToolBar); SupportActionBar.SetDisplayShowCustomEnabled(true); SupportActionBar.SetDisplayHomeAsUpEnabled(true); SupportActionBar.SetHomeButtonEnabled(true); SupportActionBar.SetDisplayShowHomeEnabled(true); //Get values Txt_Username_icon = FindViewById <AppCompatTextView>(Resource.Id.Username_icon); Txt_Username_text = FindViewById <EditText>(Resource.Id.Username_text); Txt_Email_icon = FindViewById <AppCompatTextView>(Resource.Id.Email_icon); Txt_Email_text = FindViewById <EditText>(Resource.Id.Email_text); Txt_Gender_icon = FindViewById <AppCompatTextView>(Resource.Id.Gendericon); RadioGender = FindViewById <RadioGroup>(Resource.Id.radioGender); RB_Male = (RadioButton)FindViewById(Resource.Id.radioMale); RB_Female = (RadioButton)FindViewById(Resource.Id.radioFemale); Get_Data_User(); } catch (Exception e) { Console.WriteLine(e); } }
private void BindResources() { _coordinatorLayout = FindViewById <CoordinatorLayout>(Resource.Id.nav_coordinator_content); _toolbar = FindViewById <Toolbar>(Resource.Id.nav_toolbar); _customToolbarTitleWrapper = FindViewById <LinearLayout>(Resource.Id.toolbar_title_wrapper); _customToolbarTitle = FindViewById <AppCompatTextView>(Resource.Id.toolbar_title); _customToolbarSubtitle = FindViewById <AppCompatTextView>(Resource.Id.toolbar_subtitle); _pageContainer = FindViewById <ConstraintLayout>(Resource.Id.page_container); _eventIcon = FindViewById <ImageView>(Resource.Id.event_detail_image); _eventActionPlan = FindViewById <RecyclerView>(Resource.Id.detailed_message_list); adapter = new EventDetailsAdapter(this, new List <NotificationModel>(ViewModel.Notifications)); _eventActionPlan.SetAdapter(adapter); BottomSheet = FindViewById <LinearLayout>(Resource.Id.bottom_sheet); BottomSheetBehaviour = new Edison.Mobile.Android.Common.Behaviors.BottomSheetBehavior(); CoordinatorLayout.LayoutParams lp = BottomSheet.LayoutParameters as CoordinatorLayout.LayoutParams; lp.Behavior = BottomSheetBehaviour; BottomSheet.LayoutParameters = lp; Map = FindViewById <MapView>(Resource.Id.map_container); }
public override View GetView(int position, View convertView, ViewGroup parent) { View row = convertView; if (row == null) { row = LayoutInflater.From(mContext).Inflate(Resource.Layout.patenttree_row, null, false); } AppCompatTextView patentHolderName = row.FindViewById <AppCompatTextView>(Resource.Id.name); patentHolderName.Text = mInnovations[position].Contributor; AppCompatTextView patentDescription = row.FindViewById <AppCompatTextView>(Resource.Id.description); patentDescription.Text = mInnovations[position].DescriptionShort; AppCompatTextView patentDate = row.FindViewById <AppCompatTextView>(Resource.Id.date); patentDate.Text = String.Format("{0:MMMM d, yyy}", mInnovations[position].CreationDate); return(row); }
private void DestroyBasic() { try { IconBack = null; JobCoverImage = null; JobAvatar = null; JobTitle = null; PageName = null; JobInfo = null; JobButton = null; MaximumNumber = null; MinimumNumber = null; Description = null; TxtMore = null; DialogType = null; ReadMoreOption = null; } catch (Exception e) { Console.WriteLine(e); } }
public void AddReadLess(AppCompatTextView textView, ICharSequence text) { try { textView.SetMaxLines(Integer.MaxValue); SpannableStringBuilder spendableStringBuilder = new SpannableStringBuilder(text); spendableStringBuilder.Append(" "); spendableStringBuilder.Append(LessLabel); SpannableString ss = SpannableString.ValueOf(spendableStringBuilder); ClickableSpan rclickableSpan = new StRclickableSpan(this, textView, text, StTools.StTypeText.ReadLess); ss.SetSpan(rclickableSpan, ss.Length() - LessLabel.Length, ss.Length(), SpanTypes.ExclusiveExclusive); // textView.SetTextFuture(PrecomputedTextCompat.GetTextFuture(ss, TextViewCompat.GetTextMetricsParams(textView), null)); textView.SetText(ss, TextView.BufferType.Spannable); textView.MovementMethod = (LinkMovementMethod.Instance); } catch (Exception e) { Console.WriteLine(e); } }
private void DestroyBasic() { try { IconBack = null !; JobCoverImage = null !; JobAvatar = null !; JobTitle = null !; PageName = null !; JobInfo = null !; JobButton = null !; MaximumNumber = null !; MinimumNumber = null !; Description = null !; TxtMore = null !; DialogType = null !; ReadMoreOption = null !; } catch (Exception e) { Methods.DisplayReportResultTrack(e); } }
private void setTextViewTextColorFallbackColorWhenMissingStyleAttrs(AppCompatTextView textView) { var useDefaultColor = false; try { TextViewCompat.SetTextAppearance(textView, textHelperTextAppearance); if (MarshmallowApis.AreAvailable && textView.TextColors.DefaultColor == fallbackTextColorAfterMarshmallow) { useDefaultColor = true; } } catch (Exception e) { useDefaultColor = true; } if (useDefaultColor) { TextViewCompat.SetTextAppearance(textView, Resource.Style.TextAppearance_AppCompat_Caption); Color defaultTextColor = new Color(ContextCompat.GetColor(Context, Resource.Color.defaultText)); textView.SetTextColor(defaultTextColor); } }
private void BindResources() { _coordinatorLayout = FindViewById <CoordinatorLayout>(Resource.Id.nav_coordinator_content); _drawer = FindViewById <DrawerLayout>(Resource.Id.drawer_layout); _toolbar = FindViewById <Toolbar>(Resource.Id.nav_toolbar); _customToolbarTitleWrapper = FindViewById <LinearLayout>(Resource.Id.toolbar_title_wrapper); _customToolbarTitle = FindViewById <AppCompatTextView>(Resource.Id.toolbar_title); _customToolbarSubtitle = FindViewById <AppCompatTextView>(Resource.Id.toolbar_subtitle); _profileView = FindViewById <CircularProfileView>(Resource.Id.img_profile); _profileNameView = FindViewById <AppCompatTextView>(Resource.Id.profile_name); _logoutButton = FindViewById <AppCompatTextView>(Resource.Id.logout_button); _page_container = FindViewById <FrameLayout>(Resource.Id.page_container); BottomSheet = FindViewById <LinearLayout>(Resource.Id.bottom_sheet); //BottomSheetBehaviour = Edison.Mobile.Android.Common.Behaviors.BottomSheetBehavior.From(_bottomSheet); // _bottomSheetBehaviour = BottomSheet4StateBehaviour.From(_bottomSheet); BottomSheetBehaviour = new Edison.Mobile.Android.Common.Behaviors.BottomSheetBehavior(); CoordinatorLayout.LayoutParams lp = BottomSheet.LayoutParameters as CoordinatorLayout.LayoutParams; lp.Behavior = BottomSheetBehaviour; BottomSheet.LayoutParameters = lp; _brightnessControlContainer = FindViewById <LinearLayout>(Resource.Id.brightness_slider_container); _brightnessControl = FindViewById <AppCompatSeekBar>(Resource.Id.brightness_slider); _moon = FindViewById <AppCompatImageView>(Resource.Id.moon); }
public override View OnCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { // Use this to return your custom view for this Fragment var view = LayoutInflater.Inflate(Resource.Layout.main_tab_content, container, false); recyclerView = view.FindViewById <RecyclerView>(Resource.Id.main_tab_rv); layoutManager = new CachingLayoutManager(view.Context); recyclerView.SetLayoutManager(layoutManager); recyclerView.ClearOnScrollListeners(); emptyView = view.FindViewById <AppCompatTextView>(Resource.Id.main_tab_emptytext); refreshView = view.FindViewById <SwipeRefreshLayout>(Resource.Id.main_tab_content_refresh); refreshView.SetProgressBackgroundColorSchemeResource(Resource.Color.colorPrimaryDark); if (tabType == DataEnum.DataType.TVSchedule) { refreshView.Refresh += delegate { (Activity as TVScheduleActivity).SetupScheduleData(refreshView); }; } else { refreshView.Refresh += (s, e) => { ReloadCurrentData(); }; } //AnimHelper.FadeContents(view, true, false, null); return(view); }
void UpdateTitleViewLayoutAlignment(LinearLayout titleViewLayout, AppCompatTextView titleTextView, AppCompatTextView subTitleTextView, CustomNavigationPage.TitleAlignment alignment) { var titleViewParams = titleViewLayout.LayoutParameters as Android.Widget.FrameLayout.LayoutParams; var titleTextViewParams = titleTextView.LayoutParameters as LinearLayout.LayoutParams; var subTitleTextViewParams = subTitleTextView.LayoutParameters as LinearLayout.LayoutParams; switch (alignment) { case CustomNavigationPage.TitleAlignment.Start: titleViewParams.Gravity = GravityFlags.Start | GravityFlags.CenterVertical; titleTextViewParams.Gravity = GravityFlags.Start; subTitleTextViewParams.Gravity = GravityFlags.Start; break; case CustomNavigationPage.TitleAlignment.Center: titleViewParams.Gravity = GravityFlags.Center; titleTextViewParams.Gravity = GravityFlags.Center; subTitleTextViewParams.Gravity = GravityFlags.Center; break; case CustomNavigationPage.TitleAlignment.End: titleViewParams.Gravity = GravityFlags.End | GravityFlags.CenterVertical; titleTextViewParams.Gravity = GravityFlags.End; subTitleTextViewParams.Gravity = GravityFlags.End; break; } titleViewLayout.LayoutParameters = titleViewParams; }
void UpdateTitleViewLayout(Page lastPage, Android.Widget.LinearLayout titleViewLayout, AppCompatTextView titleTextView, AppCompatTextView subTitleTextView, Android.Graphics.Drawables.Drawable defaultBackground) { UpdateTitleViewLayoutAlignment(titleViewLayout, titleTextView, subTitleTextView, CustomNavigationPage.GetTitlePosition(lastPage)); if (!string.IsNullOrEmpty(CustomNavigationPage.GetTitleBackground(lastPage))) { UpdateTitleViewLayoutBackground(titleViewLayout, CustomNavigationPage.GetTitleBackground(lastPage), defaultBackground); } else { _titleViewLayout?.SetBackground(CreateShape(ShapeType.Rectangle, (int)CustomNavigationPage.GetTitleBorderWidth(lastPage), (int)CustomNavigationPage.GetTitleBorderCornerRadius(lastPage), CustomNavigationPage.GetTitleFillColor(lastPage), CustomNavigationPage.GetTitleBorderColor(lastPage))); } UpdateTitleViewLayoutMargin(titleViewLayout, CustomNavigationPage.GetTitleMargin(lastPage)); UpdateTitleViewLayoutPadding(titleViewLayout, CustomNavigationPage.GetTitlePadding(lastPage)); }
public override void OnViewAdded(Android.Views.View child) { base.OnViewAdded(child); if (child.GetType() == typeof(Android.Support.V7.Widget.Toolbar)) { var lastPage = Element?.Navigation?.NavigationStack?.Last(); /*if (_toolbar !=null) * { * _toolbar.ChildViewAdded -= OnToolbarChildViewAdded; * var lPage = Element?.Navigation?.NavigationStack?.Last(); * lPage.PropertyChanged -= LastPage_PropertyChanged; * }*/ _toolbar = (Android.Support.V7.Widget.Toolbar)child; _originalToolbarBackground = _toolbar.Background; var originalContent = (Context as Activity)?.Window?.DecorView?.FindViewById <FrameLayout>(Window.IdAndroidContent); if (originalContent != null) { _originalWindowContent = originalContent.Foreground; } _parentLayout = new Android.Widget.FrameLayout(_toolbar.Context) { LayoutParameters = new Android.Widget.FrameLayout.LayoutParams(LayoutParams.MatchParent, LayoutParams.MatchParent) }; //Create custom title view layout _titleViewLayout = new Android.Widget.LinearLayout(_parentLayout.Context) { Orientation = Android.Widget.Orientation.Vertical, LayoutParameters = new Android.Widget.FrameLayout.LayoutParams(LayoutParams.WrapContent, LayoutParams.WrapContent) }; //Create custom title text view _titleTextView = new AppCompatTextView(_parentLayout.Context) { LayoutParameters = new LinearLayout.LayoutParams(LayoutParams.WrapContent, LayoutParams.WrapContent) }; //Create custom subtitle text view _subTitleTextView = new AppCompatTextView(_parentLayout.Context) { LayoutParameters = new LinearLayout.LayoutParams(LayoutParams.WrapContent, LayoutParams.WrapContent) }; //Add title/subtitle to title view layout _titleViewLayout.AddView(_titleTextView); _titleViewLayout.AddView(_subTitleTextView); //Add title view layout to main layout _parentLayout.AddView(_titleViewLayout); //Add main layout to toolbar _toolbar.AddView(_parentLayout); _toolbar.ChildViewAdded += OnToolbarChildViewAdded; lastPage.PropertyChanged += LastPage_PropertyChanged; } }
public SingleLineItemViewHolder(View itemView) : base(itemView) { PrimaryText = itemView.FindViewById <AppCompatTextView>(Resource.Id.text_primary); }
// Replace the contents of a view (invoked by the layout manager) public override void OnBindViewHolder(RecyclerView.ViewHolder viewHolder, int position) { try { if (viewHolder is UpgradePlansViewHolder holder) { UpgradeGoProClass item = PlansList[position]; if (item != null) { if (AppSettings.SetTabDarkTheme) { holder.MainLayout.SetBackgroundResource(Resource.Drawable.ShadowLinerLayoutDark); holder.RelativeLayout.SetBackgroundResource(Resource.Drawable.price_gopro_item_style_dark); } holder.PlanImg.SetImageResource(item.ImageResource); holder.PlanImg.SetColorFilter(Color.ParseColor(item.HexColor)); var(currency, currencyIcon) = WoWonderTools.GetCurrency(ListUtils.SettingsSiteList?.Currency); Console.WriteLine(currency); if (ListUtils.SettingsSiteList != null) { holder.PriceText.Text = currencyIcon + item.PlanPrice; } else { holder.PriceText.Text = item.PlanPrice; } holder.PlanText.Text = item.PlanText; holder.PerText.Text = item.PlanTime; holder.PlanText.SetTextColor(Color.ParseColor(item.HexColor)); holder.PriceText.SetTextColor(Color.ParseColor(item.HexColor)); holder.UpgradeButton.BackgroundTintList = ColorStateList.ValueOf(Color.ParseColor(item.HexColor)); Typeface font = Typeface.CreateFromAsset(Application.Context.Resources?.Assets, "ionicons.ttf"); string name = "go_pro_array_" + item.Id; int? resourceId = ActivityContext.Resources?.GetIdentifier(name, "array", ActivityContext.ApplicationInfo.PackageName); if (resourceId == 0) { return; } string[] planArray = ActivityContext.Resources?.GetStringArray(resourceId.Value); if (planArray != null) { foreach (string options in planArray) { if (!string.IsNullOrEmpty(options)) { AppCompatTextView text = new AppCompatTextView(ActivityContext) { Text = options, TextSize = 13 }; text.SetTextColor(AppSettings.SetTabDarkTheme ? Color.White : Color.ParseColor("#444444")); text.Gravity = GravityFlags.CenterHorizontal; text.SetTypeface(font, TypefaceStyle.Normal); WoTextDecorator.Content = options; WoTextDecorator.DecoratedContent = new Android.Text.SpannableString(options); WoTextDecorator.SetTextColor(IonIconsFonts.Checkmark, "#43a735"); WoTextDecorator.SetTextColor(IonIconsFonts.Close, "#e13c4c"); LinearLayout.LayoutParams paramsss = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MatchParent, ViewGroup.LayoutParams.WrapContent);//height and width are inpixel paramsss.SetMargins(0, 30, 0, 5); text.LayoutParameters = paramsss; holder.OptionLinerLayout.AddView(text); WoTextDecorator.Build(text, WoTextDecorator.DecoratedContent); } } } } } } catch (Exception e) { Methods.DisplayReportResultTrack(e); } }
private void InitComponent() { try { MainView = FindViewById <CoordinatorLayout>(Resource.Id.main_content); SecondReactionButton = FindViewById <TextView>(Resource.Id.SecondReactionText); MainSectionButton = FindViewById <LinearLayout>(Resource.Id.linerSecondReaction); LikeButton = FindViewById <ReactButton>(Resource.Id.beactButton); CommentCount = FindViewById <TextView>(Resource.Id.Commentcount); LikeCount = FindViewById <TextView>(Resource.Id.Likecount); TimeText = FindViewById <AppCompatTextView>(Resource.Id.time_text); PrivacyPostIcon = FindViewById <AppCompatTextView>(Resource.Id.privacyPost); MoreIcon = FindViewById <ImageView>(Resource.Id.moreicon); Username = FindViewById <TextViewWithImages>(Resource.Id.username); UserAvatar = FindViewById <CircleImageView>(Resource.Id.userAvatar); Description = FindViewById <SuperTextView>(Resource.Id.description); PostExtrasLayout = FindViewById <RelativeLayout>(Resource.Id.postExtras); ShareLinearLayout = FindViewById <LinearLayout>(Resource.Id.ShareLinearLayout); CommentLinearLayout = FindViewById <LinearLayout>(Resource.Id.CommentLinearLayout); SecondReactionLinearLayout = FindViewById <LinearLayout>(Resource.Id.SecondReactionLinearLayout); if (SecondReactionButton != null) { if (AppSettings.PostButton == PostButtonSystem.Reaction || AppSettings.PostButton == PostButtonSystem.Like) { MainSectionButton.WeightSum = 3; SecondReactionLinearLayout.Visibility = ViewStates.Gone; } else if (AppSettings.PostButton == PostButtonSystem.Wonder) { MainSectionButton.WeightSum = 4; SecondReactionLinearLayout.Visibility = ViewStates.Visible; SecondReactionButton.SetCompoundDrawablesWithIntrinsicBounds(Resource.Drawable.icon_post_wonder_vector, 0, 0, 0); SecondReactionButton.Text = Application.Context.GetText(Resource.String.Btn_Wonder); } else if (AppSettings.PostButton == PostButtonSystem.DisLike) { MainSectionButton.WeightSum = 4; SecondReactionLinearLayout.Visibility = ViewStates.Visible; SecondReactionButton.SetCompoundDrawablesWithIntrinsicBounds(Resource.Drawable.ic_action_dislike, 0, 0, 0); SecondReactionButton.Text = Application.Context.GetText(Resource.String.Btn_Dislike); } } LikeButton.SetTextColor(Color.White); if (LikeButton?.GetCurrentReaction()?.GetReactType() == ReactConstants.Default) { LikeButton.CompoundDrawableTintList = ColorStateList.ValueOf(Color.White); } YouTubeFragment = new YouTubePlayerSupportFragment(); SupportFragmentManager.BeginTransaction().Add(Resource.Id.root, YouTubeFragment, YouTubeFragment.Id.ToString() + DateTime.Now).Commit(); YouTubeFragment.Initialize(AppSettings.YoutubeKey, this); } catch (Exception e) { Console.WriteLine(e); } }
protected override void OnCreate(Bundle savedInstanceState) { try { base.OnCreate(savedInstanceState); IMethods.IApp.FullScreenApp(this); // Set our view from the "Last_Messages_Fragment" layout resource SetContentView(Resource.Layout.MyProfile_Layout); S_UserId = UserDetails.User_id; //Set ToolBar var ToolBar = FindViewById <Toolbar>(Resource.Id.myprofiletoolbar); ToolBar.Title = ""; SetSupportActionBar(ToolBar); SupportActionBar.SetDisplayShowCustomEnabled(true); SupportActionBar.SetDisplayHomeAsUpEnabled(true); SupportActionBar.SetHomeButtonEnabled(true); SupportActionBar.SetDisplayShowHomeEnabled(true); //Get values Txt_name_icon = FindViewById <AppCompatTextView>(Resource.Id.name_icon); Txt_Fullname = FindViewById <TextView>(Resource.Id.Txt_fullname); Txt_UserName = FindViewById <TextView>(Resource.Id.username); Txt_Followers = FindViewById <TextView>(Resource.Id.Txt_flowersView); Txt_FollowersCount = FindViewById <TextView>(Resource.Id.Txt_flowers_count); Txt_Following = FindViewById <TextView>(Resource.Id.flowinglabelView); Txt_FollowingCount = FindViewById <TextView>(Resource.Id.Txt_flowing_countView); Txt_FirstName = FindViewById <EditText>(Resource.Id.FirstName_text); Txt_LastName = FindViewById <EditText>(Resource.Id.LastName_text); Image_Userprofile = FindViewById <ImageView>(Resource.Id.profile_image); Image_UserCover = FindViewById <ImageView>(Resource.Id.coverImageView); Txt_gender_icon = FindViewById <AppCompatTextView>(Resource.Id.gender_icon); Txt_gender_text = FindViewById <EditText>(Resource.Id.gender_text); Txt_location_icon = FindViewById <AppCompatTextView>(Resource.Id.location_icon); Txt_location_text = FindViewById <EditText>(Resource.Id.location_text); Txt_mobile_icon = FindViewById <AppCompatTextView>(Resource.Id.mobile_icon); Txt_mobile_text = FindViewById <EditText>(Resource.Id.mobile_text); Txt_website_icon = FindViewById <AppCompatTextView>(Resource.Id.website_icon); Txt_website_text = FindViewById <EditText>(Resource.Id.website_text); Txt_work_icon = FindViewById <AppCompatTextView>(Resource.Id.work_icon); Txt_work_text = FindViewById <EditText>(Resource.Id.work_text); Txt_facebook_icon = FindViewById <AppCompatTextView>(Resource.Id.facebook_icon); Txt_facebook_text = FindViewById <EditText>(Resource.Id.facebook_text); Txt_Google_icon = FindViewById <AppCompatTextView>(Resource.Id.Google_icon); Txt_Google_text = FindViewById <EditText>(Resource.Id.Google_text); Txt_Twitter_icon = FindViewById <AppCompatTextView>(Resource.Id.Twitter_icon); Txt_Twitter_text = FindViewById <EditText>(Resource.Id.Twitter_text); Txt_VK_icon = FindViewById <AppCompatTextView>(Resource.Id.VK_icon); Txt_VK_text = FindViewById <EditText>(Resource.Id.VK_text); Txt_Instagram_icon = FindViewById <AppCompatTextView>(Resource.Id.Instagram_icon); Txt_Instagram_text = FindViewById <EditText>(Resource.Id.Instagram_text); Txt_Youtube_icon = FindViewById <AppCompatTextView>(Resource.Id.Youtube_icon); Txt_Youtube_text = FindViewById <EditText>(Resource.Id.Youtube_text); IMethods.Set_TextViewIcon("1", Txt_gender_icon, IonIcons_Fonts.Male); Txt_gender_icon.SetTextColor(Color.ParseColor("#4693d8")); IMethods.Set_TextViewIcon("1", Txt_location_icon, IonIcons_Fonts.Location); Txt_location_icon.SetTextColor(Color.ParseColor(AppSettings.MainColor)); IMethods.Set_TextViewIcon("1", Txt_mobile_icon, IonIcons_Fonts.AndroidCall); Txt_mobile_icon.SetTextColor(Color.ParseColor("#fa6670")); IMethods.Set_TextViewIcon("1", Txt_website_icon, IonIcons_Fonts.AndroidGlobe); Txt_website_icon.SetTextColor(Color.ParseColor("#6b38d1")); IMethods.Set_TextViewIcon("1", Txt_work_icon, IonIcons_Fonts.Briefcase); Txt_work_icon.SetTextColor(Color.ParseColor("#eca72c")); EditProfile_button = FindViewById <CircleButton>(Resource.Id.Edit_button); //EditProfile_button.Click += EditProfileButtonOnClick; EditProfile_button.Visibility = ViewStates.Invisible; IMethods.Set_TextViewIcon("1", Txt_name_icon, IonIcons_Fonts.Person); IMethods.Set_TextViewIcon("1", Txt_facebook_icon, IonIcons_Fonts.SocialFacebook); IMethods.Set_TextViewIcon("1", Txt_Google_icon, IonIcons_Fonts.SocialGoogle); IMethods.Set_TextViewIcon("1", Txt_Twitter_icon, IonIcons_Fonts.SocialTwitter); IMethods.Set_TextViewIcon("4", Txt_VK_icon, "\uf189"); IMethods.Set_TextViewIcon("1", Txt_Instagram_icon, IonIcons_Fonts.SocialInstagram); IMethods.Set_TextViewIcon("1", Txt_Youtube_icon, IonIcons_Fonts.SocialYoutube); AdsGoogle.Ad_Interstitial(this); mAdView = FindViewById <AdView>(Resource.Id.adView); if (AppSettings.Show_ADMOB_Banner) { mAdView.Visibility = ViewStates.Visible; string android_id = Android.Provider.Settings.Secure.GetString(this.ContentResolver, Android.Provider.Settings.Secure.AndroidId); var adRequest = new AdRequest.Builder(); adRequest.AddTestDevice(android_id); mAdView.LoadAd(adRequest.Build()); } else { mAdView.Pause(); mAdView.Visibility = ViewStates.Gone; } Txt_gender_text.SetOnClickListener(this); } catch (Exception e) { Console.WriteLine(e); } }
public override View OnCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { #region Init View var ignored = base.OnCreateView(inflater, container, savedInstanceState); View view = inflater.Inflate(Resource.Layout.content_settings, null); #endregion try { crudSettings = new CrudSettings(); settings = Settings.Instance; updateServiceIntent = new Intent(); updateServiceIntent.SetAction(Info.IntentActionUpdateSettings); updatePendingIntent = PendingIntent.GetBroadcast(context, 0, updateServiceIntent, 0); #region Popup Dialog var remoteViews = new RemoteViews(context.PackageName, Resource.Layout.layout_popup); var layoutInflater = LayoutInflater.FromContext(context); var viewPopup = layoutInflater.Inflate(remoteViews.LayoutId, null); popupDialog = new Dialog(Platform.CurrentActivity); popupDialog.SetContentView(viewPopup); popupDialog.Window.SetSoftInputMode(SoftInput.AdjustResize); var textView = viewPopup.FindViewById <TextView>(Resource.Id.textView1); buttonOkPopup = viewPopup.FindViewById <Button>(Resource.Id.button1); buttonOkPopup.Click += ButtonOk_Popup_Click; buttonCancelPopup = viewPopup.FindViewById <Button>(Resource.Id.button2); buttonCancelPopup.Click += ButtonCancel_Popup_Click; #endregion #region Сontrol element materialButtonAppInfo = view.FindViewById <MaterialButton>(Resource.Id.materialButton1); floatingActionButtonSaveSettings = view.FindViewById <FloatingActionButton>(Resource.Id.floatingActionButton1); floatingActionDefaultSettings = view.FindViewById <FloatingActionButton>(Resource.Id.floatingActionButton2); radioGroupMain = view.FindViewById <RadioGroup>(Resource.Id.radioGroup1); radioButtonUseRam = view.FindViewById <RadioButton>(Resource.Id.radioButton1); radioButtonUseCpu = view.FindViewById <RadioButton>(Resource.Id.radioButton2); swithRelativeIsViewRam = view.FindViewById <SwitchCompat>(Resource.Id.switch1); swithShowFreeRam = view.FindViewById <SwitchCompat>(Resource.Id.switch2); //swithLogging = view.FindViewById<SwitchCompat>(Resource.Id.switch3); //swithCrash = view.FindViewById<SwitchCompat>(Resource.Id.switch4); switchCompatUseCpu = view.FindViewById <SwitchCompat>(Resource.Id.switchCompat1); switchAbsoluteIsViewRam = view.FindViewById <SwitchCompat>(Resource.Id.switchCompat2); switchLayoutLotification = view.FindViewById <SwitchCompat>(Resource.Id.switchCompat3); sbSizeDigits = view.FindViewById <AppCompatSeekBar>(Resource.Id.seekBar1); sbPositionAbscissa = view.FindViewById <AppCompatSeekBar>(Resource.Id.seekBar3); sbPositionOrdinate = view.FindViewById <AppCompatSeekBar>(Resource.Id.seekBar4); sbUpdateTimer = view.FindViewById <AppCompatSeekBar>(Resource.Id.seekBar5); spinnerTypefaceDigits = view.FindViewById <Spinner>(Resource.Id.spinner1); spinnerTextColorDigits = view.FindViewById <Spinner>(Resource.Id.spinner3); spinnerCanvasColor = view.FindViewById <Spinner>(Resource.Id.spinner5); spinnerCanvasMaterial = view.FindViewById <Spinner>(Resource.Id.spinner6); tvsbSizeDigits = view.FindViewById <TextView>(Resource.Id.textView2); tvsbSwithRelativeIsViewRam = view.FindViewById <TextView>(Resource.Id.textView4); tvsbTypefaceDigits = view.FindViewById <TextView>(Resource.Id.textView5); tvsbPositionAbscissa = view.FindViewById <TextView>(Resource.Id.textView10); tvsbPositionOrdinate = view.FindViewById <TextView>(Resource.Id.textView11); tvsbSwithIsShowFreeRam = view.FindViewById <TextView>(Resource.Id.textView13); tvsbUpdateTimer = view.FindViewById <TextView>(Resource.Id.textView14); //tvsbLogging = view.FindViewById<TextView>(Resource.Id.textView15); //tvsbCrash = view.FindViewById<TextView>(Resource.Id.textView16); tvsbLayoutLotification = view.FindViewById <AppCompatTextView>(Resource.Id.appCompatTextView3); tvsbSwithIsShowFreeCpu = view.FindViewById <AppCompatTextView>(Resource.Id.appCompatTextView1); tvsbSwithAbsoluteIsViewRam = view.FindViewById <AppCompatTextView>(Resource.Id.appCompatTextView2); materialButtonAppInfo.Click += MaterialButtonAppInfo_Click; floatingActionButtonSaveSettings.Click += ButtonSaveSettings_Click; floatingActionDefaultSettings.Click += ButtonDefaultSettings_Click; radioButtonUseRam.Click += RadioButtonUseRam_Click; adapter = ArrayAdapter.CreateFromResource(context, Resource.Array.array_typeface_style, Android.Resource.Layout.SimpleSpinnerItem); adapter.SetDropDownViewResource(Android.Resource.Layout.SimpleSpinnerDropDownItem); adapterColor = ArrayAdapter.CreateFromResource(context, Resource.Array.array_color, Android.Resource.Layout.SimpleSpinnerItem); adapterColor.SetDropDownViewResource(Android.Resource.Layout.SimpleSpinnerDropDownItem); adapterMaterial = ArrayAdapter.CreateFromResource(context, Resource.Array.array_material, Android.Resource.Layout.SimpleSpinnerItem); adapterMaterial.SetDropDownViewResource(Android.Resource.Layout.SimpleSpinnerDropDownItem); spinnerTypefaceDigits.Adapter = adapter; spinnerTextColorDigits.Adapter = adapterColor; spinnerCanvasColor.Adapter = adapterColor; spinnerCanvasMaterial.Adapter = adapterMaterial; sbSizeDigits.ProgressChanged += SbSizeDigits_ProgressChanged; sbPositionAbscissa.ProgressChanged += SbPositionAbscissa_ProgressChanged; sbPositionOrdinate.ProgressChanged += SbPositionOrdinate_ProgressChanged; swithRelativeIsViewRam.CheckedChange += SwithRelativeIsViewRam_CheckedChange; swithShowFreeRam.CheckedChange += SwithShowFreeRam_CheckedChange; //swithLogging.CheckedChange += SwithLogging_CheckedChange; //swithCrash.CheckedChange += SwithCrash_CheckedChange; switchCompatUseCpu.CheckedChange += SwitchCompatUseCpu_CheckedChange; switchAbsoluteIsViewRam.CheckedChange += SwitchAbsoluteIsViewRam_CheckedChange; switchLayoutLotification.CheckedChange += SwitchLayoutLotification_CheckedChange; spinnerTypefaceDigits.ItemSelected += SpinnerTypefaceDigits_ItemSelected; spinnerCanvasColor.ItemSelected += SpinnerCanvasColor_ItemSelected; spinnerTextColorDigits.ItemSelected += SpinnerTextColorDigits_ItemSelected; spinnerCanvasMaterial.ItemSelected += SpinnerCanvasMaterial_ItemSelected; if (settings.ProVersion == false) { sbUpdateTimer.ProgressDrawable.SetColorFilter(Color.Olive, PorterDuff.Mode.SrcAtop); sbUpdateTimer.Thumb.SetColorFilter(Color.Olive, PorterDuff.Mode.SrcAtop); radioButtonUseCpu.SetTextColor(Color.Olive); spinnerTypefaceDigits.SetBackgroundColor(Color.Olive); spinnerCanvasColor.SetBackgroundColor(Color.Olive); spinnerTextColorDigits.SetBackgroundColor(Color.Olive); spinnerCanvasMaterial.SetBackgroundColor(Color.Olive); sbUpdateTimer.Touch += SbUpdateTimer_Touch; radioButtonUseCpu.Touch += RadioButtonUseCpu_Touch; spinnerTypefaceDigits.Touch += Spinner_Touch; spinnerCanvasColor.Touch += Spinner_Touch; spinnerTextColorDigits.Touch += Spinner_Touch; spinnerCanvasMaterial.Touch += Spinner_Touch; } else { sbUpdateTimer.ProgressChanged += SbUpdateTimer_ProgressChanged; radioButtonUseCpu.Click += RadioButtonUseCpu_Click; spinnerTypefaceDigits.ItemSelected += SpinnerTypefaceDigits_ItemSelected; spinnerCanvasColor.ItemSelected += SpinnerCanvasColor_ItemSelected; spinnerTextColorDigits.ItemSelected += SpinnerTextColorDigits_ItemSelected; spinnerCanvasMaterial.ItemSelected += SpinnerCanvasMaterial_ItemSelected; } UpdateView(); #endregion return(view); } catch (System.Exception ex) { #region Logging LogRuntimeAttribute.InLogFiles(typeof(SettingsFragment), ex); #endregion return(view); } finally { } }
private void BindViews(View item) { Button = item.FindViewById <CircularImageButton>(Resource.Id.button); Label = item.FindViewById <AppCompatTextView>(Resource.Id.label); }
public StRunnable(StReadMoreOption option, AppCompatTextView textView, ICharSequence text) { Option = option; TextView = textView; Text = text; }
private void BindViews(View item) { Avatar = item.FindViewById <CircularProfileView>(Resource.Id.chat_avatar); Text = item.FindViewById <AppCompatTextView>(Resource.Id.chat_text); }
private void InitComponent() { try { MainView = FindViewById <CoordinatorLayout>(Resource.Id.main_content); SecondReactionButton = FindViewById <TextView>(Resource.Id.SecondReactionText); MainSectionButton = FindViewById <LinearLayout>(Resource.Id.linerSecondReaction); LikeButton = FindViewById <ReactButton>(Resource.Id.ReactButton); CommentCount = FindViewById <TextView>(Resource.Id.Commentcount); LikeCount = FindViewById <TextView>(Resource.Id.Likecount); TimeText = FindViewById <AppCompatTextView>(Resource.Id.time_text); PrivacyPostIcon = FindViewById <AppCompatTextView>(Resource.Id.privacyPost); MoreIcon = FindViewById <ImageView>(Resource.Id.moreicon); Username = FindViewById <TextViewWithImages>(Resource.Id.username); UserAvatar = FindViewById <CircleImageView>(Resource.Id.userAvatar); Description = FindViewById <SuperTextView>(Resource.Id.description); PostExtrasLayout = FindViewById <RelativeLayout>(Resource.Id.postExtras); ShareLinearLayout = FindViewById <LinearLayout>(Resource.Id.ShareLinearLayout); CommentLinearLayout = FindViewById <LinearLayout>(Resource.Id.CommentLinearLayout); SecondReactionLinearLayout = FindViewById <LinearLayout>(Resource.Id.SecondReactionLinearLayout); if (SecondReactionButton != null) { if (AppSettings.PostButton == PostButtonSystem.ReactionDefault || AppSettings.PostButton == PostButtonSystem.ReactionSubShine || AppSettings.PostButton == PostButtonSystem.Like) { MainSectionButton.WeightSum = 3; SecondReactionLinearLayout.Visibility = ViewStates.Gone; } else if (AppSettings.PostButton == PostButtonSystem.Wonder) { MainSectionButton.WeightSum = 4; SecondReactionLinearLayout.Visibility = ViewStates.Visible; SecondReactionButton.SetCompoundDrawablesWithIntrinsicBounds(Resource.Drawable.icon_post_wonder_vector, 0, 0, 0); SecondReactionButton.Text = Application.Context.GetText(Resource.String.Btn_Wonder); } else if (AppSettings.PostButton == PostButtonSystem.DisLike) { MainSectionButton.WeightSum = 4; SecondReactionLinearLayout.Visibility = ViewStates.Visible; SecondReactionButton.SetCompoundDrawablesWithIntrinsicBounds(Resource.Drawable.ic_action_dislike, 0, 0, 0); SecondReactionButton.Text = Application.Context.GetText(Resource.String.Btn_Dislike); } } LikeButton.SetTextColor(Color.White); //if (LikeButton?.GetCurrentReaction()?.GetReactType() == ReactConstants.Default) //{ // LikeButton.CompoundDrawableTintList = ColorStateList.ValueOf(Color.White); //} YouTubePlayerView youTubeView = new YouTubePlayerView(this); var youtubeView = FindViewById <FrameLayout>(Resource.Id.root); youtubeView.RemoveAllViews(); youtubeView.AddView(youTubeView); youTubeView.Initialize(AppSettings.YoutubeKey, this); } catch (Exception e) { Methods.DisplayReportResultTrack(e); } }
public AddNewCall_AdapterViewHolder(View itemView, Action <AddNewCall_AdapterClickEventArgs> clickListener, Action <AddNewCall_AdapterClickEventArgs> longClickListener , Action <AddNewCall_AdapterClickEventArgs> AudioCallclickListener, Action <AddNewCall_AdapterClickEventArgs> VideoCallclickListener) : base(itemView) { try { MainView = itemView; //Get values RelativeLayout_main = (RelativeLayout)MainView.FindViewById(Resource.Id.main); Txt_Username = (TextView)MainView.FindViewById(Resource.Id.Txt_Username); Txt_platform = (TextView)MainView.FindViewById(Resource.Id.Txt_Userplatform); ImageAvatar = (ImageView)MainView.FindViewById(Resource.Id.Img_Avatar); Image_Lastseen = (CircleImageView)MainView.FindViewById(Resource.Id.Img_Lastseen); Txt_IconAudioCall = (AppCompatTextView)MainView.FindViewById(Resource.Id.IconAudioCall); Txt_IconVideoCall = (AppCompatTextView)MainView.FindViewById(Resource.Id.IconVideoCall); itemView.Click += (sender, e) => clickListener(new AddNewCall_AdapterClickEventArgs { View = itemView, Position = AdapterPosition }); itemView.LongClick += (sender, e) => longClickListener(new AddNewCall_AdapterClickEventArgs { View = itemView, Position = AdapterPosition }); Txt_IconAudioCall.Click += (sender, e) => AudioCallclickListener(new AddNewCall_AdapterClickEventArgs { View = itemView, Position = AdapterPosition }); Txt_IconVideoCall.Click += (sender, e) => VideoCallclickListener(new AddNewCall_AdapterClickEventArgs { View = itemView, Position = AdapterPosition }); FontController.SetFont(Txt_Username, 1); FontController.SetFont(Txt_platform, 3); if (AppSettings.Enable_Video_Call) { Txt_IconVideoCall.Visibility = ViewStates.Visible; IMethods.Set_TextViewIcon("1", Txt_IconVideoCall, IonIcons_Fonts.IosVideocam); } else { Txt_IconVideoCall.Visibility = ViewStates.Gone; } if (AppSettings.Enable_Audio_Call) { Txt_IconAudioCall.Visibility = ViewStates.Visible; IMethods.Set_TextViewIcon("1", Txt_IconAudioCall, IonIcons_Fonts.AndroidCall); Txt_IconAudioCall.SetTextColor(Color.ParseColor(AppSettings.MainColor)); } else { Txt_IconAudioCall.Visibility = ViewStates.Gone; } ImageCacheLoader.LoadImage("no_profile_image.png", ImageAvatar, false, true); } catch (Exception e) { Console.WriteLine(e); } }