コード例 #1
0
        public void RemoveView_IsRemovedFromViewsCollection()
        {
            ViewStub view = new ViewStub();

            mainForm.AddView(view);
            mainForm.RemoveView(view);

            Assert.AreEqual(0, mainForm.Views.Count);
        }
コード例 #2
0
        public void AddView_AddDuplicateView_ThrowsException()
        {
            ViewStub view = new ViewStub();

            TestDelegate testDelegate = () =>
            {
                mainForm.AddView(view);
                mainForm.AddView(view);
            };

            Assert.That(testDelegate, Throws.Exception.TypeOf<Exception>());
        }
コード例 #3
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();
                RewardedVideoAd?.OnDestroy(this);

                MAdapter           = null;
                SwipeRefreshLayout = null;
                MRecycler          = null;
                EmptyStateLayout   = null;
                Inflated           = null;
                MainScrollEvent    = null;
                MAdView            = null;
                RewardedVideoAd    = null;
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #4
0
        private void InitComponent(View view)
        {
            try
            {
                MRecycler        = (RecyclerView)view.FindViewById(Resource.Id.recyler);
                EmptyStateLayout = view.FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = (SwipeRefreshLayout)view.FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = false;
                SwipeRefreshLayout.Enabled    = false;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));

                MAdView = view.FindViewById <AdView>(Resource.Id.adView);
                AdsGoogle.InitAdView(MAdView, MRecycler);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #5
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();

                MAdapter           = null;
                SwipeRefreshLayout = null;
                MRecycler          = null;
                EmptyStateLayout   = null;
                Inflated           = null;
                MainScrollEvent    = null;
                ActionButton       = null;
                Instance           = null;
                MAdView            = null;
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #6
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();

                MAdapter           = null !;
                SwipeRefreshLayout = null !;
                MRecycler          = null !;
                EmptyStateLayout   = null !;
                Inflated           = null !;
                MainScrollEvent    = null !;
                GroupId            = null !;
                ItemJoinRequests   = null !;
                MAdView            = null !;
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #7
0
        private void InitComponent()
        {
            try
            {
                MRecycler        = (RecyclerView)FindViewById(Resource.Id.recyler);
                EmptyStateLayout = FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = (SwipeRefreshLayout)FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = true;
                SwipeRefreshLayout.Enabled    = true;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));

                MAdView = FindViewById <AdView>(Resource.Id.adView);
                AdsGoogle.InitAdView(MAdView, MRecycler);
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #8
0
        private void InitComponent()
        {
            try
            {
                EmptyStateLayout = FindViewById <ViewStub>(Resource.Id.viewStub);

                SuggestedGroupViewStub = FindViewById <ViewStub>(Resource.Id.viewStubSuggestedGroup);
                CatGroupViewStub       = FindViewById <ViewStub>(Resource.Id.viewStubCatGroup);
                RandomGroupViewStub    = FindViewById <ViewStub>(Resource.Id.viewStubRandomGroup);

                SwipeRefreshLayout = (SwipeRefreshLayout)FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = true;
                SwipeRefreshLayout.Enabled    = true;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #9
0
        private void InitComponent()
        {
            try
            {
                MRecycler        = (RecyclerView)FindViewById(Resource.Id.recyler);
                EmptyStateLayout = FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = (SwipeRefreshLayout)FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = false;
                SwipeRefreshLayout.Enabled    = false;
                SwipeRefreshLayout.SetPadding(5, 0, 0, 0);

                MAdView = FindViewById <AdView>(Resource.Id.adView);
                AdsGoogle.InitAdView(MAdView, MRecycler);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #10
0
        private void InitComponent(View view)
        {
            try
            {
                MRecycler        = view.FindViewById <RecyclerView>(Resource.Id.recyler);
                EmptyStateLayout = view.FindViewById <ViewStub>(Resource.Id.viewStub);

                MRecycler.SetPadding(50, 0, 0, 60);

                SwipeRefreshLayout = view.FindViewById <SwipeRefreshLayout>(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = true;
                SwipeRefreshLayout.Enabled    = true;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));
                SwipeRefreshLayout.Refresh += SwipeRefreshLayoutOnRefresh;
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #11
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();
                RewardedVideoAd?.OnDestroy(this);

                MAdapter           = null !;
                SwipeRefreshLayout = null !;
                MRecycler          = null !;
                EmptyStateLayout   = null !;
                Inflated           = null !;
                MainScrollEvent    = null !;
                MAdView            = null !;
                RewardedVideoAd    = null !;
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #12
0
        private void InitComponent(View view)
        {
            try
            {
                TabButtons       = view.FindViewById <LinearLayout>(Resource.Id.TabButtons);
                MRecycler        = (RecyclerView)view.FindViewById(Resource.Id.NotifcationRecyler);
                EmptyStateLayout = view.FindViewById <ViewStub>(Resource.Id.viewStub);
                MatchesButton    = view.FindViewById <RelativeLayout>(Resource.Id.MatchesButton);
                LikesButton      = view.FindViewById <RelativeLayout>(Resource.Id.LikesButton);
                VisitsButton     = view.FindViewById <RelativeLayout>(Resource.Id.VisitsButton);
                MatchesLayout    = view.FindViewById <LinearLayout>(Resource.Id.bt1);
                VisitsLayout     = view.FindViewById <LinearLayout>(Resource.Id.bt2);
                LikesLayout      = view.FindViewById <LinearLayout>(Resource.Id.bt3);

                MatchesImage = view.FindViewById <ImageView>(Resource.Id.ImageView1);
                VisitsImage  = view.FindViewById <ImageView>(Resource.Id.ImageView2);
                LikesImage   = view.FindViewById <ImageView>(Resource.Id.ImageView3);

                MatchesTextView = view.FindViewById <TextView>(Resource.Id.text1);
                LikesTextView   = view.FindViewById <TextView>(Resource.Id.text3);
                VisitsTextView  = view.FindViewById <TextView>(Resource.Id.text2);

                IconFriend            = view.FindViewById <TextView>(Resource.Id.friend_icon);
                IconFriend.Visibility = ViewStates.Gone;

                FontUtils.SetTextViewIcon(FontsIconFrameWork.FontAwesomeRegular, IconFriend, FontAwesomeIcon.UserPlus);

                SwipeRefreshLayout = (SwipeRefreshLayout)view.FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = true;
                SwipeRefreshLayout.Enabled    = true;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));

                MatchesButton.Tag = "Clicked";
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #13
0
        private void InitComponent(View view)
        {
            try
            {
                MRecycler        = (RecyclerView)view.FindViewById(Resource.Id.recyler);
                EmptyStateLayout = view.FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = (SwipeRefreshLayout)view.FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = false;
                SwipeRefreshLayout.Enabled    = true;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));
                SwipeRefreshLayout.Refresh += SwipeRefreshLayoutOnRefresh;

                LayoutFriendRequest = (RelativeLayout)view.FindViewById(Resource.Id.layout_friend_Request);

                FriendRequestImage1 = (ImageView)view.FindViewById(Resource.Id.image_page_1);
                FriendRequestImage2 = (ImageView)view.FindViewById(Resource.Id.image_page_2);
                FriendRequestImage3 = (ImageView)view.FindViewById(Resource.Id.image_page_3);

                TxTFriendRequest    = (TextView)view.FindViewById(Resource.Id.tv_Friends_connection);
                TxtAllFriendRequest = (TextView)view.FindViewById(Resource.Id.tv_Friends);

                if (AppSettings.ConnectivitySystem == 1)
                {
                    TxTFriendRequest.Text    = Context.GetString(Resource.String.Lbl_FollowRequest);
                    TxtAllFriendRequest.Text = Context.GetString(Resource.String.Lbl_View_All_FollowRequest);
                }

                LayoutFriendRequest.Click     += LayoutFriendRequestOnClick;
                LayoutFriendRequest.Visibility = ViewStates.Gone;

                MAdView = view.FindViewById <AdView>(Resource.Id.adView);
                AdsGoogle.InitAdView(MAdView, MRecycler);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #14
0
        private void InitComponent()
        {
            try
            {
                RootView = FindViewById <LinearLayout>(Resource.Id.main_content);

                MRecycler = (RecyclerView)FindViewById(Resource.Id.recycler_view);

                EmojisView    = FindViewById <ImageView>(Resource.Id.emojiicon);
                TxtComment    = FindViewById <EmojiconEditText>(Resource.Id.commenttext);
                ImgSent       = FindViewById <ImageView>(Resource.Id.send);
                ImgGallery    = FindViewById <ImageView>(Resource.Id.image);
                ImgBack       = FindViewById <ImageView>(Resource.Id.back);
                CommentLayout = FindViewById <ViewStub>(Resource.Id.comment_layout);

                ReplyCountTextView = FindViewById <TextView>(Resource.Id.replyCountTextview);

                if (AppSettings.FlowDirectionRightToLeft)
                {
                    ImgBack.SetImageResource(Resource.Drawable.ic_action_ic_back_rtl);
                }

                ImgGallery.SetImageDrawable(AppSettings.SetTabDarkTheme ? GetDrawable(Resource.Drawable.ic_action_addpost_Ligth) : GetDrawable(Resource.Drawable.ic_action_AddPost));

                ReplyCountTextView.Text = CommentObject?.Replies + " " + GetString(Resource.String.Lbl_Replies);

                Methods.SetColorEditText(TxtComment, AppSettings.SetTabDarkTheme ? Color.White : Color.Black);

                TxtComment.Text = "";
                PathImage       = "";

                var emojisIcon = new EmojIconActions(this, RootView, TxtComment, EmojisView);
                emojisIcon.ShowEmojIcon();
                emojisIcon.SetIconsIds(Resource.Drawable.ic_action_keyboard, Resource.Drawable.ic_action_sentiment_satisfied_alt);
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #15
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();

                MAdapter           = null !;
                SwipeRefreshLayout = null !;
                MRecycler          = null !;
                EmptyStateLayout   = null !;
                Inflated           = null !;
                MainScrollEvent    = null !;
                BtnFilter          = null !;
                CategoryId         = null !;
                UserId             = null !;
                MAdView            = null !;
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #16
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();

                MAdapter           = null;
                SwipeRefreshLayout = null;
                MRecycler          = null;
                EmptyStateLayout   = null;
                Inflated           = null;
                Instance           = null;
                CreateButton       = null;
                TxtSuggestedGroups = null;
                UserId             = null;
                MAdView            = null;
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #17
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();
                RewardedVideo?.Destroy();

                MAdapter           = null !;
                SwipeRefreshLayout = null !;
                MRecycler          = null !;
                EmptyStateLayout   = null !;
                Inflated           = null !;
                IdPost             = null !;
                TypePost           = null !;
                MAdView            = null !;
                RewardedVideo      = null !;
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #18
0
 private void DestroyBasic()
 {
     try
     {
         Instance           = null !;
         MAdapter           = null !;
         MRecycler          = null !;
         CommentLayout      = null !;
         CommentLayoutView  = null !;
         ReplyCountTextView = null !;
         ImgBack            = null !;
         ImgSent            = null !;
         ImgGallery         = null !;
         CommentObject      = null !;
         CommentId          = null !;
         PathImage          = null !;
     }
     catch (Exception e)
     {
         Methods.DisplayReportResultTrack(e);
     }
 }
コード例 #19
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();

                MAdapter            = null !;
                SwipeRefreshLayout  = null !;
                MRecycler           = null !;
                EmptyStateLayout    = null !;
                Inflated            = null !;
                ItemUser            = null !;
                InviteFriendsButton = null !;
                PageId        = null !;
                MAdView       = null !;
                PageDataClass = null !;
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #20
0
        private void SetRecyclerViewAdapters()
        {
            try
            {
                MainRecyclerView = FindViewById <WRecyclerView>(Resource.Id.Recyler);
                EmptyStateLayout = FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = FindViewById <SwipeRefreshLayout>(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = true;
                SwipeRefreshLayout.Enabled    = true;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));

                PostFeedAdapter = new NativePostAdapter(this, "", MainRecyclerView, NativeFeedType.Memories);

                MainRecyclerView.SetXAdapter(PostFeedAdapter, SwipeRefreshLayout);
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #21
0
 private void DestroyBasic()
 {
     try
     {
         Instance           = null;
         MAdapter           = null;
         MainRecyclerView   = null;
         CommentLayout      = null;
         CommentLayoutView  = null;
         ReplyCountTextView = null;
         ImgBack            = null;
         ImgSent            = null;
         ImgGallery         = null;
         CommentObject      = null;
         CommentId          = null;
         PathImage          = null;
     }
     catch (Exception e)
     {
         Console.WriteLine(e);
     }
 }
コード例 #22
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();

                MAdapter           = null;
                SwipeRefreshLayout = null;
                MRecycler          = null;
                EmptyStateLayout   = null;
                Inflated           = null;
                MainScrollEvent    = null;
                BtnFilter          = null;
                CategoryId         = null;
                UserId             = null;
                MAdView            = null;
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #23
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();

                MAdapter            = null;
                SwipeRefreshLayout  = null;
                MRecycler           = null;
                EmptyStateLayout    = null;
                Inflated            = null;
                ItemUser            = null;
                InviteFriendsButton = null;
                PageId        = null;
                MAdView       = null;
                PageDataClass = null;
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #24
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();
                RewardedVideo?.Destroy();

                MAdapter           = null;
                SwipeRefreshLayout = null;
                MRecycler          = null;
                EmptyStateLayout   = null;
                Inflated           = null;
                IdPost             = null;
                TypePost           = null;
                MAdView            = null;
                RewardedVideo      = null;
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #25
0
        private void InitComponent(View view)
        {
            try
            {
                ImageUser        = (ImageView)view.FindViewById(Resource.Id.ImageUser);
                ImageAct         = (ImageView)view.FindViewById(Resource.Id.ImageAct);
                NameUser         = view.FindViewById <TextView>(Resource.Id.NameUser);
                TimeUser         = view.FindViewById <TextView>(Resource.Id.TimeUser);
                ContentAct       = view.FindViewById <TextView>(Resource.Id.ContentAct);
                LikeActLayout    = view.FindViewById <LinearLayout>(Resource.Id.LikeActLayout);
                IconLikeAct      = view.FindViewById <TextView>(Resource.Id.IconLikeAct);
                CountLikeAct     = view.FindViewById <TextView>(Resource.Id.CountLikeAct);
                DislikeActLayout = view.FindViewById <LinearLayout>(Resource.Id.DislikeActLayout);
                IconDislikeAct   = view.FindViewById <TextView>(Resource.Id.IconDislikeAct);
                CountDislikeAct  = view.FindViewById <TextView>(Resource.Id.CountDislikeAct);
                CommentActLayout = view.FindViewById <LinearLayout>(Resource.Id.CommentActLayout);
                IconCommentAct   = view.FindViewById <TextView>(Resource.Id.IconCommentAct);
                CountCommentAct  = view.FindViewById <TextView>(Resource.Id.CountCommentAct);

                EmptyStateLayout = view.FindViewById <ViewStub>(Resource.Id.viewStub);
                MRecycler        = view.FindViewById <RecyclerView>(Resource.Id.recycler_view);
                TxtComment       = view.FindViewById <EditText>(Resource.Id.commenttext);
                ImgSent          = view.FindViewById <ImageView>(Resource.Id.send);

                SwipeRefreshLayout = view.FindViewById <SwipeRefreshLayout>(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = false;
                SwipeRefreshLayout.Enabled    = false;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));

                TxtComment.Text = "";
                Methods.SetColorEditText(TxtComment, AppSettings.SetTabDarkTheme ? Color.White : Color.Black);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #26
0
        private void InitComponent()
        {
            try
            {
                MRecycler        = (RecyclerView)FindViewById(Resource.Id.recyler);
                EmptyStateLayout = FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = (SwipeRefreshLayout)FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = false;
                SwipeRefreshLayout.Enabled    = false;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));

                ProgressBarLoader            = (ProgressBar)FindViewById(Resource.Id.sectionProgress);
                ProgressBarLoader.Visibility = ViewStates.Gone;

                FloatingActionButtonView = FindViewById <FloatingActionButton>(Resource.Id.floatingActionButtonView);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #27
0
ファイル: SearchFragment.cs プロジェクト: divitiae/playtube
        private void InitComponent(View view)
        {
            try
            {
                CatRecycler = (RecyclerView)view.FindViewById(Resource.Id.catigoriesRecyler);

                MRecycler        = (RecyclerView)view.FindViewById(Resource.Id.recyler);
                EmptyStateLayout = view.FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = (SwipeRefreshLayout)view.FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = false;
                SwipeRefreshLayout.Enabled    = false;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));

                FilterButton = (TextView)view.FindViewById(Resource.Id.filter_icon);
                FontUtils.SetTextViewIcon(FontsIconFrameWork.IonIcons, FilterButton, IonIconsFonts.AndroidOptions);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #28
0
        private void InitComponent(View view)
        {
            try
            {
                MRecycler        = (RecyclerView)view.FindViewById(Resource.Id.recyler);
                EmptyStateLayout = view.FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = (SwipeRefreshLayout)view.FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = true;
                SwipeRefreshLayout.Enabled    = true;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));

                SwipeRefreshLayout.Refresh += SwipeRefreshLayoutOnRefresh;

                LinearLayout adContainer = view.FindViewById <LinearLayout>(Resource.Id.bannerContainer);
                BannerAd = AdsFacebook.InitAdView(Activity, adContainer);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #29
0
        private void DestroyBasic()
        {
            try
            {
                MAdView?.Destroy();

                MAdapter           = null !;
                SwipeRefreshLayout = null !;
                MRecycler          = null !;
                EmptyStateLayout   = null !;
                Inflated           = null !;
                MainScrollEvent    = null !;
                BtnAction          = null !;
                ToolBar            = null !;
                SearchView         = null !;
                SearchText         = null !;
                MAdView            = null !;
            }
            catch (Exception e)
            {
                Methods.DisplayReportResultTrack(e);
            }
        }
コード例 #30
0
        private void InitComponent(View view)
        {
            try
            {
                MRecycler        = (RecyclerView)view.FindViewById(Resource.Id.recyler);
                EmptyStateLayout = view.FindViewById <ViewStub>(Resource.Id.viewStub);

                SwipeRefreshLayout = (SwipeRefreshLayout)view.FindViewById(Resource.Id.swipeRefreshLayout);
                SwipeRefreshLayout.SetDefaultStyle();

                FilterButton = (TextView)view.FindViewById(Resource.Id.toolbar_title);
                FontUtils.SetTextViewIcon(FontsIconFrameWork.IonIcons, FilterButton, IonIconsFonts.AndroidOptions);
                FilterButton.SetTextColor(Color.White);
                FilterButton.SetTextSize(ComplexUnitType.Sp, 20f);
                FilterButton.Visibility = ViewStates.Visible;

                ShowGoogleAds(view, MRecycler);
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #31
0
        private void InitComponent()
        {
            try
            {
                IconClose = CommentWindow.FindViewById <TextView>(Resource.Id.IconColse);

                RootView               = CommentWindow.FindViewById <RelativeLayout>(Resource.Id.root);
                EmojisIcon             = CommentWindow.FindViewById <AppCompatImageView>(Resource.Id.emojiicon);
                EmojisIconEditTextView = CommentWindow.FindViewById <EmojiconEditText>(Resource.Id.EmojiconEditText5);
                SendButton             = CommentWindow.FindViewById <CircleButton>(Resource.Id.sendButton);
                MRecycler              = CommentWindow.FindViewById <RecyclerView>(Resource.Id.recyler);
                SwipeRefreshLayout     = CommentWindow.FindViewById <SwipeRefreshLayout>(Resource.Id.swipeRefreshLayout);
                ProgressBarLoader      = CommentWindow.FindViewById <ProgressBar>(Resource.Id.sectionProgress);
                EmptyStateLayout       = CommentWindow.FindViewById <ViewStub>(Resource.Id.viewStub);

                SendButton.Click += SendButtonOnClick;
                IconClose.Click  += IconCloseOnClick;

                SwipeRefreshLayout.SetColorSchemeResources(Android.Resource.Color.HoloBlueLight, Android.Resource.Color.HoloGreenLight, Android.Resource.Color.HoloOrangeLight, Android.Resource.Color.HoloRedLight);
                SwipeRefreshLayout.Refreshing = false;
                SwipeRefreshLayout.Enabled    = true;
                SwipeRefreshLayout.SetProgressBackgroundColorSchemeColor(AppSettings.SetTabDarkTheme ? Color.ParseColor("#424242") : Color.ParseColor("#f7f7f7"));
                SwipeRefreshLayout.Refresh += SwipeRefreshLayout_Refresh;

                FontUtils.SetTextViewIcon(FontsIconFrameWork.FontAwesomeLight, IconClose, FontAwesomeIcon.Times);

                ProgressBarLoader.Visibility = ViewStates.Visible;

                var emojis = new EmojIconActions(ActivityContext, RootView, EmojisIconEditTextView, EmojisIcon);
                emojis.ShowEmojIcon();
                EmojisIconEditTextView.RequestFocus();
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #32
0
        private void InitComponent(View view)
        {
            try
            {
                FilterButton       = view.FindViewById <ImageView>(Resource.Id.Filterbutton);
                NearByRecyclerView = (RecyclerView)view.FindViewById(Resource.Id.Recylerusers);
                ProgressBarLoader  = (ProgressBar)view.FindViewById(Resource.Id.sectionProgress);
                EmptyStateLayout   = view.FindViewById <ViewStub>(Resource.Id.viewStub);
                ToolbarTitle       = view.FindViewById <TextView>(Resource.Id.toolbartitle);
                ProRecyclerView    = (RecyclerView)view.FindViewById(Resource.Id.proRecyler);

                HotOrNotLinear  = (LinearLayout)view.FindViewById(Resource.Id.HotORNotLinear);
                IconHotOrNot    = (TextView)view.FindViewById(Resource.Id.iconHotORNot);
                RecylerHotOrNot = (RecyclerView)view.FindViewById(Resource.Id.recylerHotOrNot);
                FontUtils.SetTextViewIcon(FontsIconFrameWork.IonIcons, IconHotOrNot, IonIconsFonts.IosFlameOutline);

                ToolbarTitle.Text = AppSettings.ApplicationName;

                SwipeRefreshLayout = (SpringView)view.FindViewById(Resource.Id.material_style_ptr_frame);
                SwipeRefreshLayout.SetType(SpringView.Type.Overlap);
                SwipeRefreshLayout.Header = new Helpers.PullSwipeStyles.DefaultHeader(Activity);
                SwipeRefreshLayout.Footer = new Helpers.PullSwipeStyles.DefaultFooter(Activity);
                SwipeRefreshLayout.Enable = true;
                SwipeRefreshLayout.SetListener(this);

                AppBarLayout = (AppBarLayout)view.FindViewById(Resource.Id.appBarLayout);
                AppBarLayout.SetExpanded(false);

                ProgressBarLoader.Visibility  = ViewStates.Visible;
                NearByRecyclerView.Visibility = ViewStates.Gone;
                HotOrNotLinear.Visibility     = ViewStates.Gone;
            }
            catch (Exception e)
            {
                Console.WriteLine(e);
            }
        }
コード例 #33
0
        public void SetActiveView_FiresActiveViewChangedEvent_FormerAndCurrentActiveViewsAreOfExpectedTypes()
        {
            ViewStub expectedView = new ViewStub();

            IView actualView = null;

            mainForm.OnActiveViewChanged += (oldActiveView, newActiveView) =>
            {
                actualView = newActiveView;
            };

            mainForm.SetActiveView(expectedView);

            Assert.AreEqual(expectedView, actualView);
        }
コード例 #34
0
        public void RemoveView_ViewIsActive_MakesActiveViewNull()
        {
            ViewStub view = new ViewStub();

            mainForm.AddView(view);
            mainForm.SetActiveView(view);
            mainForm.RemoveView(view);

            Assert.IsNull(mainForm.ActiveView);
        }
コード例 #35
0
        public void RemoveView_ViewIsActive_FiresActiveViewChangedEvent()
        {
            bool fired = false;

            IView fakeView = new ViewStub();

            mainForm.AddView(fakeView);

            mainForm.SetActiveView(fakeView);

            mainForm.OnActiveViewChanged += delegate { fired = true; };

            mainForm.RemoveView(fakeView);

            Assert.IsTrue(fired);
        }
コード例 #36
0
        public void SetActiveView_IsExpectedActiveView()
        {
            ViewStub view = new ViewStub();

            mainForm.AddView(view);
            mainForm.SetActiveView(view);

            Assert.AreEqual(view, mainForm.ActiveView);
        }