DrawImage() to OnPaint().
svn path=/trunk/mcs/; revision=35027
// Peter Bartok pbartok@novell.com
//
// $Log: ButtonBase.cs,v $
+// Revision 1.15 2004/10/15 13:32:45 ravindra
+// - Renamed Paint() method to Draw() for clarity. Also, moved
+// DrawImage() to OnPaint().
+//
// Revision 1.14 2004/10/15 13:16:10 ravindra
// - Redraw () is not virtual now.
// - Added an internal virtual method Paint (), so that
Refresh ();
}
- // Derived classes should override Paint method and we dont want
+ // Derived classes should override Draw method and we dont want
// to break the control signature, hence this approach.
- internal virtual void Paint (PaintEventArgs pevent) {
+ internal virtual void Draw (PaintEventArgs pevent) {
if (redraw) {
ThemeEngine.Current.DrawButtonBase(this.DeviceContext, pevent.ClipRectangle, this);
redraw = false;
}
-
- pevent.Graphics.DrawImage(this.ImageBuffer, pevent.ClipRectangle, pevent.ClipRectangle, GraphicsUnit.Pixel);
}
private void RedrawEvent(object sender, System.EventArgs e) {
}
protected override void OnPaint(PaintEventArgs pevent) {
- Paint (pevent);
+ Draw (pevent);
+ pevent.Graphics.DrawImage(this.ImageBuffer, pevent.ClipRectangle, pevent.ClipRectangle, GraphicsUnit.Pixel);
base.OnPaint (pevent);
}
//
//
// $Log: CheckBox.cs,v $
+// Revision 1.10 2004/10/15 13:32:45 ravindra
+// - Renamed Paint() method to Draw() for clarity. Also, moved
+// DrawImage() to OnPaint().
+//
// Revision 1.9 2004/10/15 13:25:50 ravindra
// - Removed Redraw (), we get it from ButtonBase.
// - Implemented Paint (), to do class specific painting.
#endregion // Events
#region Internal drawing code
- internal override void Paint (PaintEventArgs pe) {
+ internal override void Draw (PaintEventArgs pe) {
if (redraw) {
ThemeEngine.Current.DrawCheckBox (this.DeviceContext, this.ClientRectangle, this);
redraw = false;
}
- pe.Graphics.DrawImage (this.ImageBuffer, pe.ClipRectangle, pe.ClipRectangle, GraphicsUnit.Pixel);
}
#endregion // Internal drawing code
}
// Peter Bartok pbartok@novell.com
//
// $Log: RadioButton.cs,v $
+// Revision 1.8 2004/10/15 13:32:45 ravindra
+// - Renamed Paint() method to Draw() for clarity. Also, moved
+// DrawImage() to OnPaint().
+//
// Revision 1.7 2004/10/15 13:25:50 ravindra
// - Removed Redraw (), we get it from ButtonBase.
// - Implemented Paint (), to do class specific painting.
#endregion // Events
#region Internal Drawing Code
- internal override void Paint (PaintEventArgs pe) {
+ internal override void Draw (PaintEventArgs pe) {
if (redraw) {
ThemeEngine.Current.DrawRadioButton(this.DeviceContext, this.ClientRectangle, this);
redraw = false;
}
-
- pe.Graphics.DrawImage (this.ImageBuffer, pe.ClipRectangle, pe.ClipRectangle, GraphicsUnit.Pixel);
}
#endregion // Internal Drawing Code
}