Example #1
0
        private static void MakeBusyIconVisibleOnEmptyFilter(GotoByNameMenu menu, GotoByNameModel model, Lifetime lifetime)
        {
            EditboxGlyph     glyph  = null;
            EditboxCueBanner banner = null;
            JetPopupMenuView view   = menu.MenuView.GetValue();

            foreach (Control control in view.Title.QuickSearchEditbox.Controls)
            {
                glyph  = glyph ?? control as EditboxGlyph;
                banner = banner ?? control as EditboxCueBanner;
                if (glyph != null && banner != null)
                {
                    break;
                }
            }

            IProperty <bool> property = model.IsReady.CreateNot(lifetime);
            IProperty <bool> target   = new Property <bool>(lifetime, "isShowGlyphDeferred");
            PropertyBindingDeferred <bool> propertyBindingDeferred =
                new PropertyBindingDeferred <bool>(lifetime, property, target, TimeSpan.FromSeconds(0.3));

            target.Change.Advise_HasNew(lifetime, args => glyph.Visible = args.New);
            property.WhenTrueOnce(lifetime, () => banner.Visible        = false);
        }
Example #2
0
 public static void ConfigureMenuView([NotNull] JetPopupMenuView menuView)
 {
     new ContextMenuSectionNavigationConfigurator(menuView).Configure();
 }
Example #3
0
 private ContextMenuSectionNavigationConfigurator([NotNull] JetPopupMenuView menuView)
 {
     this.MenuView = menuView;
 }