Exemplo n.º 1
0
 public NavigationBarItemSelectedEventArgs(NavigationBarItem item)
 {
     this.Item = item;
 }
 public NavigationBarItemSelectedEventArgs(NavigationBarItem item)
 {
     this.Item = item;
 }
Exemplo n.º 3
0
        void INavigationBarPresenter.PresentItems(
            IList<NavigationBarProjectItem> projects,
            NavigationBarProjectItem selectedProject,
            IList<NavigationBarItem> types,
            NavigationBarItem selectedType,
            NavigationBarItem selectedMember)
        {
            _projectItems = projects;
            _currentTypeItems = types;

            // It's possible we're presenting items before the dropdown bar has been initialized.
            if (_dropdownBar == null)
            {
                return;
            }

            var projectIndex = selectedProject != null ? _projectItems.IndexOf(selectedProject) : -1;
            var typeIndex = selectedType != null ? _currentTypeItems.IndexOf(selectedType) : -1;
            var memberIndex = selectedType != null && selectedMember != null ? selectedType.ChildItems.IndexOf(selectedMember) : -1;

            _dropdownBar.RefreshCombo((int)NavigationBarDropdownKind.Project, projectIndex);
            _dropdownBar.RefreshCombo((int)NavigationBarDropdownKind.Type, typeIndex);
            _dropdownBar.RefreshCombo((int)NavigationBarDropdownKind.Member, memberIndex);
        }