Example #1
0
 private void UpdateAutoHideItems()
 {
     CollectionUtil.Synchronize(GetAutoHideItems(),
                                _autoHideItems,
                                delegate(int index, DockItem item) { _autoHideItems.Insert(index, item); },
                                delegate(DockItem item) { _autoHideItems.Remove(item); });
 }
Example #2
0
 private void UpdateDocuments()
 {
     CollectionUtil.Synchronize(GetDocuments(),
                                _documents,
                                delegate(int index, DockItem item) { _documents.Insert(index, item); },
                                delegate(DockItem item) { _documents.Remove(item); });
 }
Example #3
0
 private void InsertVisibleItem(int index, DockItem item)
 {
     Debug.Assert(!_visibleItems.Contains(item));
     if (index < _selectedItemIndex)
     {
         _selectedItemIndex++;
     }
     _visibleItems.Insert(index, item);
 }
Example #4
0
        private void UpdateActiveItems()
        {
            CollectionUtil.Synchronize(GetActiveItems(),
                                       _activeItems,
                                       delegate(int index, DockItem item) { _activeItems.Insert(index, item); },
                                       delegate(DockItem item) { _activeItems.Remove(item); });

            Debug.Assert(_activeItems.Count == _visibleItems.Count);
        }