[mono/monodevelop] c4269467: [Debugger] Conditional hit type combo should always be visible.

"Therzok ([email protected])" <[email protected]>
Newsgroups gmane.comp.gnome.mono.patches
Message-ID <0000014204bda1e8-365b3e8c-6190-4bfc-91fc-47516b649dc6-000000@email.amazonses.com>
   Branch: refs/heads/bpDialog2
     Home: https://github.com/mono/monodevelop
  Compare: https://github.com/mono/monodevelop/compare/9e8caba4038b...c4269467b116

   Commit: c4269467b1167a480bd6a36198e3d849f3fd6e79
   Author: Therzok <[email protected]> (Therzok)
     Date: 2013-10-29 15:02:16 GMT
      URL: https://github.com/mono/monodevelop/commit/c4269467b1167a480bd6a36198e3d849f3fd6e79

[Debugger] Conditional hit type combo should always be visible.

Changed paths:
  M main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger/BreakpointPropertiesDialog.cs
  M main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger/DebuggingService.cs

Modified: main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger/BreakpointPropertiesDialog.cs
===================================================================
@@ -41,7 +41,7 @@ enum ConditionalHitWhen
 		ExpressionChanges
 	}
 
-	sealed class BreakpointPropertiesDialog2 : Xwt.Dialog
+	sealed class BreakpointPropertiesDialog : Xwt.Dialog
 	{
 		// For button sensitivity.
 		Xwt.DialogButton buttonOk;
@@ -88,7 +88,7 @@ sealed class BreakpointPropertiesDialog2 : Xwt.Dialog
 		string parsedFunction;
 		readonly HashSet<string> classes = new HashSet<string> ();
 
-		public BreakpointPropertiesDialog2 (BreakEvent be)
+		public BreakpointPropertiesDialog (BreakEvent be)
 		{
 			this.be = be;
 
@@ -117,6 +117,9 @@ void Initialize ()
 			ignoreHitType.Items.Add (HitCountMode.MultipleOf, GettextCatalog.GetString ("when hit count is a multiple of"));
 
 			ignoreHitCount.IncrementValue = 1;
+			ignoreHitCount.ClimbRate = 1;
+			ignoreHitCount.MinimumValue = 0;
+			ignoreHitCount.MaximumValue = Int32.MaxValue;
 
 			conditionalHitType.Items.Add (ConditionalHitWhen.ConditionIsTrue, GettextCatalog.GetString ("is true"));
 			conditionalHitType.Items.Add (ConditionalHitWhen.ExpressionChanges, GettextCatalog.GetString ("expression changes"));
@@ -305,10 +308,7 @@ void OnUpdateControls (object sender, EventArgs e)
 			hboxCondition.Sensitive = !stopOnException.Active && DebuggingService.IsFeatureSupported (DebuggerFeatures.ConditionalBreakpoints);
 
 			// Check conditional
-			if (!String.IsNullOrEmpty (entryConditionalExpression.Text))
-				conditionalHitType.Show ();
-			else
-				conditionalHitType.Hide ();
+			conditionalHitType.Sensitive = !String.IsNullOrEmpty (entryConditionalExpression.Text);
 
 			// Check ignoring hit counts.
 			if (ignoreHitType.SelectedItem.Equals (HitCountMode.None))


Modified: main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger/DebuggingService.cs
===================================================================
@@ -217,7 +217,7 @@ public static void ShowValueVisualizer (ObjectValue val)
 		
 		public static bool ShowBreakpointProperties (ref BreakEvent bp)
 		{
-			using (var dlg = new BreakpointPropertiesDialog2 (bp)) {
+			using (var dlg = new BreakpointPropertiesDialog (bp)) {
 				Xwt.Command response = dlg.Run ();
 				if (bp == null)
 					bp = dlg.GetBreakEvent ();


_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.