[mono/monodevelop] fdf5fe42: Cleanup in Breakpoints Dialog

"Ungureanu Marius ([email protected])" <[email protected]>
Newsgroups gmane.comp.gnome.mono.patches
Message-ID <000001418289f0c1-085a65a8-7946-4f7b-be4f-38b7626f9191-000000@email.amazonses.com>
   Branch: refs/heads/bpDialog
     Home: https://github.com/mono/monodevelop
  Compare: https://github.com/mono/monodevelop/commit/fdf5fe42ebe3

   Commit: fdf5fe42ebe341ff35de7c7d23003a4dd61aaaaa
   Author: Ungureanu Marius <[email protected]> (Therzok)
     Date: 2013-10-04 07:54:01 GMT
      URL: https://github.com/mono/monodevelop/commit/fdf5fe42ebe341ff35de7c7d23003a4dd61aaaaa

Cleanup in Breakpoints Dialog

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

Modified: main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger/BreakpointPropertiesDialog.cs
===================================================================
@@ -26,7 +26,6 @@
 //
 
 using System;
-using System.Collections.Generic;
 
 using MonoDevelop.Core;
 using Mono.Debugging.Client;
@@ -39,8 +38,8 @@ public partial class BreakpointPropertiesDialog : Gtk.Dialog
 	{
 		string[] parsedParamTypes;
 		string parsedFunction;
-		Breakpoint bp;
-		bool isNew;
+		readonly Breakpoint bp;
+		readonly bool isNew;
 		
 		public BreakpointPropertiesDialog (Breakpoint bp, bool isNew)
 		{
@@ -55,7 +54,7 @@ public BreakpointPropertiesDialog (Breakpoint bp, bool isNew)
 			spinLine.Adjustment.Lower = 1;
 			
 			if (bp is FunctionBreakpoint) {
-				FunctionBreakpoint fb = (FunctionBreakpoint) bp;
+				var fb = (FunctionBreakpoint) bp;
 				
 				labelFileFunction.LabelProp = GettextCatalog.GetString ("Function:");
 				
@@ -78,7 +77,7 @@ public BreakpointPropertiesDialog (Breakpoint bp, bool isNew)
 				tableLocation.NRows--;
 			} else {
 				labelFileFunction.LabelProp = GettextCatalog.GetString ("File:");
-				entryFileFunction.Text = ((Breakpoint) bp).FileName;
+				entryFileFunction.Text = bp.FileName;
 				
 				// We don't use ".Sensitive = false" because we want the user to be able to select & copy the text.
 				entryFileFunction.ModifyBase (Gtk.StateType.Normal, Style.Backgrounds [(int)Gtk.StateType.Insensitive]);
@@ -207,7 +206,7 @@ public void Save ()
 		{
 			if (isNew) {
 				if (bp is FunctionBreakpoint) {
-					FunctionBreakpoint fb = (FunctionBreakpoint) bp;
+					var fb = (FunctionBreakpoint) bp;
 					
 					fb.FunctionName = parsedFunction;
 					fb.ParamTypes = parsedParamTypes;


_______________________________________________
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.