private void changeConentDescription(DescriptionMode descriptionMode) { componentsDescriptionMode = descriptionMode; for (int i = 0; i < asmContentTree.Items.Count; i++) { TreeViewItem typeItem = asmContentTree.Items[i] as TreeViewItem; if (typeItem.Header is AssemblyTypeData) { AssemblyTypeData type = typeItem.Header as AssemblyTypeData; type.TypeDescriptionMode = descriptionMode; typeItem.Header = null; typeItem.Header = type; } for (int j = 0; j < typeItem.Items.Count; j++) { TreeViewItem methodItem = typeItem.Items[j] as TreeViewItem; if (methodItem.Header is AssemblyMethodData) { AssemblyMethodData method = methodItem.Header as AssemblyMethodData; method.MethodDescriptionMode = descriptionMode; methodItem.Header = null; methodItem.Header = method; } } } }
private string GetDictionaryValue(Dictionary <DescriptionMode, object> descList, DescriptionMode mode) { return((descList.ContainsKey(mode) == false) ? string.Empty : string.Format("{0}", descList[mode])); }