Пример #1
0
        /*
         *  Categories Dialog
         */

        private void OpenCategoriesDialog(int position)
        {
            var auth = _authenticatorSource.Authenticators.ElementAtOrDefault(position);

            if (auth == null)
            {
                return;
            }

            var fragment = new AssignCategoriesBottomSheet(_categorySource, position, _authenticatorSource.GetCategories(position));

            fragment.CategoryClick         += OnCategoriesDialogCategoryClick;
            fragment.ManageCategoriesClick += (sender, e) =>
            {
                StartChildActivity(typeof(ManageCategoriesActivity));
                fragment.Dismiss();
            };
            fragment.Close += OnCategoriesDialogClose;
            fragment.Show(SupportFragmentManager, fragment.Tag);
        }
Пример #2
0
        private void OpenCategoriesDialog(int position)
        {
            var auth = _authSource.Get(position);

            if (auth == null)
            {
                return;
            }

            var fragment = new AssignCategoriesBottomSheet(_categorySource, position, _authSource.GetCategories(position));

            fragment.CategoryClick         += OnCategoriesDialogCategoryClick;
            fragment.ManageCategoriesClick += delegate
            {
                _refreshOnActivityResume = true;
                StartActivity(typeof(ManageCategoriesActivity));
                fragment.Dismiss();
            };
            fragment.Close += OnCategoriesDialogClose;
            fragment.Show(SupportFragmentManager, fragment.Tag);
        }