- Same goes for setting the image size. Just resize them all
[mono.git] / mcs / class / Managed.Windows.Forms / System.Windows.Forms / DataGrid.cs
index 835fe373f58961b9417f0b5ba3953f9335db335a..932e81686d4577a3a178d8d2e5dde466f9e9bbc2 100644 (file)
@@ -130,7 +130,6 @@ namespace System.Windows.Forms
                private Color alternating_backcolor;
                private Color backColor;
                private Color background_color;
-               internal BorderStyle border_style;
                private Color caption_backcolor;
                private Font caption_font;
                private Color caption_forecolor;
@@ -251,7 +250,7 @@ namespace System.Windows.Forms
                        vert_scrollbar.Scroll += new ScrollEventHandler (GridVScrolled);                        
                        KeyUp += new KeyEventHandler (OnKeyUpDG);                       
 
-                       SetStyle (ControlStyles.UserPaint | ControlStyles.AllPaintingInWmPaint, true);
+                       SetStyle (ControlStyles.UserMouse, true);
 
                }
 
@@ -336,16 +335,11 @@ namespace System.Windows.Forms
                [DispId(-504)]
                [DefaultValue(BorderStyle.Fixed3D)]
                public BorderStyle BorderStyle {
-                       get {
-                               return border_style;
-                       }
-
-                       set {
-                                if (border_style != value) {
-                                       border_style = value;
-                                       CalcAreasAndInvalidate ();
-                                       OnBorderStyleChanged (EventArgs.Empty);                                 
-                               }
+                       get { return InternalBorderStyle; }
+                       set { 
+                               InternalBorderStyle = value; 
+                               CalcAreasAndInvalidate ();
+                               OnBorderStyleChanged (EventArgs.Empty);
                        }
                }