- Timestamp:
- 03/23/15 11:41:19 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/NewItemDialog/HeuristicLab.Optimizer/3.3/NewItemDialog.cs
r12235 r12238 197 197 198 198 // select first item 199 if ( selectedType == null) {199 if (SelectedType == null) { 200 200 var firstNode = FirstVisibleNode; 201 201 while (firstNode != null && !(firstNode.Tag is Type)) … … 217 217 218 218 private bool FilterNode(TreeNode node, string[] searchTokens) { 219 if (node.Tag is string) { 219 if (node.Tag is string) { // Category node 220 220 int i = 0; 221 221 while (i < node.Nodes.Count) { … … 226 226 } 227 227 return node.Nodes.Count == 0; 228 } else if (node.Tag is Type) { 228 } 229 if (node.Tag is Type) { // Type node 229 230 var text = node.Text; 230 231 if (searchTokens.Any(searchToken => !text.ToLower().Contains(searchToken))) { 231 232 var typeTag = (Type)node.Tag; 232 if (typeTag.Equals(SelectedType)) 233 if (typeTag.Equals(SelectedType)) { 233 234 SelectedType = null; 235 typesTreeView.SelectedNode = null; 236 } 234 237 return true; 235 238 } 236 239 return false; 237 } else { 238 return true; 239 } 240 } 241 return true; 240 242 } 241 243
Note: See TracChangeset
for help on using the changeset viewer.