protected override void OnCreate(Bundle savedInstanceState)
        {
            _lang  = app.GetString("Language", "en");
            UserID = app.GetString("USERID", string.Empty);
            ChangeLanguage(_lang);
            base.OnCreate(savedInstanceState);

            // Create your application here
            SetContentView(Resource.Layout.activity_wishlist);
            mToolbar        = FindViewById <Android.Support.V7.Widget.Toolbar>(Resource.Id.toolbar);
            mBottomNav      = FindViewById <BottomNavigationView>(Resource.Id.bottom_navigation_view);
            mBottomCardView = FindViewById <CardView>(Resource.Id.bottom_cardview);
            LoadingSkeleton = FindViewById <ShimmerRecyclerView>(Resource.Id.shimmer_recycler_view);
            progressBar     = FindViewById <ProgressBar>(Resource.Id.progressBar);
            recyclerView    = FindViewById <RecyclerView>(Resource.Id.recyclerView);

            LoadingSkeleton.SetLayoutManager(new LinearLayoutManager(this));
            LoadingSkeleton.ShowShimmerAdapter();
            mBottomNav.SetOnNavigationItemSelectedListener(this);

            SetSupportActionBar(mToolbar);
            SupportActionBar ab = SupportActionBar;

            ab.SetDisplayHomeAsUpEnabled(true);
            SupportActionBar.Title    = "Wishlist";
            mPageOffset               = 0;
            mCurrentLayoutManagerType = MyEnum.ListView;
            InitDecoration();
            SetUpRecyclerView(recyclerView);
            p.GetProduct += P_GetProduct;

            _products = new List <Products>();
            progressBar.Visibility = ViewStates.Invisible;
            UserWishList();
        }
        public override View OnCreateView(LayoutInflater inflater, ViewGroup container,
                                          Bundle savedInstanceState)
        {
            // Inflate the layout for this fragment
            View view = inflater.Inflate(Resource.Layout.fragment_top__deals_, container, false);


            rv_top_selling = (ShimmerRecyclerView)view.FindViewById(Resource.Id.recyclerTopSelling);
            progressDialog = new ProgressDialog(this.Context);
            progressDialog.SetMessage("Loading...");
            progressDialog.SetCancelable(false);

            viewall        = (TextView)view.FindViewById(Resource.Id.viewall_topdeals);
            viewall.Click += delegate
            {
                //startActivity(new Intent(getActivity(), ViewAll_TopDeals.class));
            };

            if (isOnline())
            {
                topSellingUrl();
                getCartDetails();
            }

            return(view);
        }
Beispiel #3
0
        protected override void OnCreate(Bundle savedInstanceState)
        {
            UserID = app.GetString("USERID", string.Empty);
            _lang  = app.GetString("Language", "en");
            ChangeLanguage(_lang);
            filters     = -1;
            SubCategory = Intent.GetStringExtra("SubCategory");

            CountWatched();

            base.OnCreate(savedInstanceState);

            CategoryTitle = Intent.GetStringExtra("Title");

            // Create your application here
            SetContentView(Resource.Layout.shopping_main);
            mDrawerLayout   = FindViewById <DrawerLayout>(Resource.Id.drawer_layout);
            mBottomNav      = FindViewById <BottomNavigationView>(Resource.Id.bottom_navigation_view);
            mBottomCardView = FindViewById <CardView>(Resource.Id.bottom_cardview);
            mLoaderEffect   = FindViewById <ShimmerRecyclerView>(Resource.Id.shimmer_recycler_view);
            mToolbar        = FindViewById <Android.Support.V7.Widget.Toolbar>(Resource.Id.toolbar);

            progressBar = FindViewById <ProgressBar>(Resource.Id.progressBar);

            mLoaderEffect.SetLayoutManager(new LinearLayoutManager(this));
            mLoaderEffect.ShowShimmerAdapter();

            SetSupportActionBar(mToolbar);
            SupportActionBar ab = SupportActionBar;

            ab.SetDisplayHomeAsUpEnabled(true);

            mBottomNav.SetOnNavigationItemSelectedListener(this);

            recyclerView = FindViewById <RecyclerView>(Resource.Id.recyclerView);
            progressBar  = FindViewById <ProgressBar>(Resource.Id.progressBar);
            InitDecoration();

            mPageOffset = 0;
            mCurrentLayoutManagerType = MyEnum.ListView;
            InitDecoration();
            SetUpRecyclerView(recyclerView);

            products = new List <Products>();

            Category      = Intent.GetStringExtra("CategoryID");
            CategoryTitle = Intent.GetStringExtra("Category");


            SupportActionBar.Title = CategoryTitle;

            GetProducts();
            CurrentMode = APIMode.Direct;
        }