- Timestamp:
- 07/25/10 00:29:17 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Core.Views/3.3/ItemCollectionView.cs
r4068 r4096 158 158 removeButton.Enabled = (Content != null) && !Content.IsReadOnly && !ReadOnly && itemsListView.SelectedItems.Count > 0; 159 159 AdjustListViewColumnSizes(); 160 if (itemsListView.SelectedItems.Count == 1) { 161 T item = (T)itemsListView.SelectedItems[0].Tag; 162 detailsGroupBox.Enabled = true; 163 viewHost.Content = item; 164 } else { 165 viewHost.Content = null; 166 detailsGroupBox.Enabled = false; 160 if (showDetailsCheckBox.Checked) { 161 if (itemsListView.SelectedItems.Count == 1) { 162 T item = (T)itemsListView.SelectedItems[0].Tag; 163 detailsGroupBox.Enabled = true; 164 viewHost.Content = item; 165 } else { 166 viewHost.Content = null; 167 detailsGroupBox.Enabled = false; 168 } 167 169 } 168 170 } … … 242 244 #endregion 243 245 246 #region CheckBox Events 247 protected virtual void showDetailsCheckBox_CheckedChanged(object sender, EventArgs e) { 248 if (showDetailsCheckBox.Checked) { 249 splitContainer.Panel2Collapsed = false; 250 detailsGroupBox.Enabled = itemsListView.SelectedItems.Count == 1; 251 viewHost.Content = itemsListView.SelectedItems.Count == 1 ? (T)itemsListView.SelectedItems[0].Tag : null; 252 } else { 253 splitContainer.Panel2Collapsed = true; 254 viewHost.Content = null; 255 viewHost.ClearCache(); 256 } 257 } 258 #endregion 259 244 260 #region Content Events 245 261 protected virtual void Content_ItemsAdded(object sender, CollectionItemsChangedEventArgs<T> e) {
Note: See TracChangeset
for help on using the changeset viewer.