public override DataTemplate SelectTemplate(object item, DependencyObject container)
        {
            if (list == null)
            {
                var picker = ElementTreeHelper.FindVisualAncestor<JumpListGroupPicker>(container);
                if (picker != null)
                {
                    list = picker.Owner;
                }
            }

            if (list == null)
            {
                return base.SelectTemplate(item, container);
            }

            return IsLinkedItem(item) ? linkedItemTemplate : emptyItemTemplate;
        }
Exemplo n.º 2
0
        private void ChangeCheckModeAction(bool onOff, RadJumpList listBox, object item)
        {
            if (onOff)
            {
                if (item != null && !listBox.CheckedItems.Contains(item))
                {
                    try { listBox.CheckedItems.Add(item); }
                    catch (InvalidOperationException) { /* Item already checked. Do nothing. */ }
                }

                if (_contactsViewModel.CurrentDisplayMode != ContactDisplayMode.CONTACTS_MULTISELECT)
                {
                    _contactsViewModel.PreviousDisplayMode = _contactsViewModel.CurrentDisplayMode;
                }
                _contactsViewModel.CurrentDisplayMode = ContactDisplayMode.CONTACTS_MULTISELECT;
            }
            else
            {
                listBox.CheckedItems.Clear();
                _contactsViewModel.CurrentDisplayMode = _contactsViewModel.PreviousDisplayMode;
            }
        }
Exemplo n.º 3
0
 public void SetJumpList(RadJumpList jump)
 {
     this._jumpList = jump;
 }
Exemplo n.º 4
0
 public HomePageViewModel(RadJumpList forumsJumpList)
     : base()
 {
     this.SetJumpList(forumsJumpList);
 }
Exemplo n.º 5
0
 public void SetJumpList(RadJumpList list)
 {
     this._jumpList = list;
     this._jumpList.SortDescriptorsSource = this.SortData;
     this.RefreshGroups(Settings.Current.ForumGrouping);
 }