protected virtual void OnOK (object sender, System.EventArgs e)
		{
			if (currentSelection != null) {
				result = currentSelection.Subject;
			} else {
				result = null;
			}
		}
示例#2
0
 protected virtual void OnOK(object sender, System.EventArgs e)
 {
     if (currentSelection != null)
     {
         result = currentSelection.Subject;
     }
     else
     {
         result = null;
     }
 }
		static IHeapItemSetStatisticsSubject ChooseSubject (IHeapItemSetStatisticsBySubject[] subjects, string subjectName) {
			IHeapItemSetStatisticsSubject result;
			if (chooser == null) {
				chooser = new LoadedClassChooser ();
			}
			chooser.Title = "Choose " + subjectName;
			chooser.FillList (subjects);
			ResponseType response = (ResponseType) chooser.Run ();
			if (response == ResponseType.Ok) {
				result = chooser.result;
			} else {
				result = null;
			}
			chooser.Hide ();
			return result;
		}
示例#4
0
        static IHeapItemSetStatisticsSubject ChooseSubject(IHeapItemSetStatisticsBySubject[] subjects, string subjectName)
        {
            IHeapItemSetStatisticsSubject result;

            if (chooser == null)
            {
                chooser = new LoadedClassChooser();
            }
            chooser.Title = "Choose " + subjectName;
            chooser.FillList(subjects);
            ResponseType response = (ResponseType)chooser.Run();

            if (response == ResponseType.Ok)
            {
                result = chooser.result;
            }
            else
            {
                result = null;
            }
            chooser.Hide();
            return(result);
        }
示例#5
0
        public static LoadedClass ChooseClass(IHeapItemSetStatisticsBySubject[] subjects)
        {
            IHeapItemSetStatisticsSubject result = ChooseSubject(subjects, "class");

            return(result as LoadedClass);
        }
示例#6
0
 protected virtual void OnCancel(object sender, System.EventArgs e)
 {
     result = null;
 }
示例#7
0
        public static StackTrace ChooseCallStack(IHeapItemSetStatisticsBySubject[] subjects)
        {
            IHeapItemSetStatisticsSubject result = ChooseSubject(subjects, "call stack");

            return(result as StackTrace);
        }
示例#8
0
        public static LoadedMethod ChooseMethod(IHeapItemSetStatisticsBySubject[] subjects)
        {
            IHeapItemSetStatisticsSubject result = ChooseSubject(subjects, "method");

            return(result as LoadedMethod);
        }
		protected virtual void OnCancel (object sender, System.EventArgs e)
		{
			result = null;
		}