ButtonBase.cs :  » 2.6.4-mono-.net-core » System.Windows.Forms » System » Windows » Forms » C# / CSharp Open Source

Home
C# / CSharp Open Source
1.2.6.4 mono .net core
2.2.6.4 mono core
3.Aspect Oriented Frameworks
4.Bloggers
5.Build Systems
6.Business Application
7.Charting Reporting Tools
8.Chat Servers
9.Code Coverage Tools
10.Content Management Systems CMS
11.CRM ERP
12.Database
13.Development
14.Email
15.Forum
16.Game
17.GIS
18.GUI
19.IDEs
20.Installers Generators
21.Inversion of Control Dependency Injection
22.Issue Tracking
23.Logging Tools
24.Message
25.Mobile
26.Network Clients
27.Network Servers
28.Office
29.PDF
30.Persistence Frameworks
31.Portals
32.Profilers
33.Project Management
34.RSS RDF
35.Rule Engines
36.Script
37.Search Engines
38.Sound Audio
39.Source Control
40.SQL Clients
41.Template Engines
42.Testing
43.UML
44.Web Frameworks
45.Web Service
46.Web Testing
47.Wiki Engines
48.Windows Presentation Foundation
49.Workflows
50.XML Parsers
C# / C Sharp
C# / C Sharp by API
C# / CSharp Tutorial
C# / CSharp Open Source » 2.6.4 mono .net core » System.Windows.Forms 
System.Windows.Forms » System » Windows » Forms » ButtonBase.cs
//
// System.Windows.Forms.ButtonBase.cs
//
// Author:
//   stubbed out by Jaak Simm (jaaksimm@firm.ee)
//    implemented for Gtk+ by Rachel Hestilow (hestilow@ximian.com)
//   Dennis Hayes (dennish@Raytek.com)
//   WINELib implementation started by John Sohn (jsohn@columbus.rr.com)
//
// (C) Ximian, Inc., 2002
//

using System.ComponentModel;
using System.Drawing;

namespace System.Windows.Forms{

  /// <summary>
  /// Implements the basic functionality common to button controls.
  /// ToDo note:
  ///  - no methods are implemented
  /// </summary>

  public abstract class ButtonBase : Control {

    // private fields
    FlatStyle flatStyle;
    Image image;
    ContentAlignment imageAlign;
    int imageIndex;
    ContentAlignment textAlign;
    ImeMode imeMode;
    bool isDefault;
    CreateParams createParams;
//    
//    // --- Constructor ---
    protected ButtonBase() : base() 
    {
      flatStyle = FlatStyle.Standard;
      image = null;
      imageAlign = ContentAlignment.MiddleCenter;
      imageIndex = -1;
      textAlign = ContentAlignment.MiddleCenter;
      imeMode = ImeMode.Inherit;
      isDefault = false;
    }
    
    // --- Properties ---
    protected override CreateParams CreateParams {
      get { return createParams; }
    }
    
    protected override ImeMode DefaultImeMode {
      get {
        return ImeMode.Inherit;
      }
    }
    
    protected override Size DefaultSize {
      get { return base.DefaultSize; }
    }
    
    public FlatStyle FlatStyle {
      get { return flatStyle; }
      set { flatStyle=value; }
    }
    
    public Image Image {
      get { return image; }
      set { image=value; }
    }
    
    public ContentAlignment ImageAlign {
      get { return imageAlign; }
      set { imageAlign=value; }
    }
    
    public int ImageIndex {
      get { return imageIndex; }
      set { imageIndex=value; }
    }
    
    public new ImeMode ImeMode {
      get {
        return imeMode; }
      set {
        imeMode = value;
      }
    }
    
    protected bool IsDefault {
      get {
        return isDefault;
      }
      set {
        isDefault = value;
      }
    }

    [MonoTODO]
    //public virtual ContentAlignment TextAlign {
    //  get { return label.TextAlign; }
    //  set { label.TextAlign = value; }
    //}

    /// --- Methods ---
    /// internal .NET framework supporting methods, not stubbed out:
    /// - protected override void Dispose(bool);
    /// - protected void ResetFlagsandPaint();
    
    
    // I do not think this is part of the spec.
    //protected override AccessibleObject CreateAccessibilityInstance() 
    //{
    //  throw new NotImplementedException ();
    //}
    
    /// [methods for events]
    protected override void OnEnabledChanged (EventArgs e) 
    {
      base.OnEnabledChanged (e);
    }
    
    protected override void OnGotFocus (EventArgs e) 
    {
      base.OnGotFocus (e);
    }
    
    protected override void OnKeyDown (KeyEventArgs kevent) 
    {
      base.OnKeyDown (kevent);
    }
    
    protected override void OnKeyUp (KeyEventArgs kevent) 
    {
      base.OnKeyUp (kevent);
    }
    
    protected override void OnLostFocus (EventArgs e) 
    {
      base.OnLostFocus (e);
    }
    
    protected override void OnMouseDown (MouseEventArgs e) 
    {
      base.OnMouseDown (e);
    }
    
    protected override void OnMouseEnter (EventArgs e) 
    {
      base.OnMouseEnter (e);
    }
    
    protected override void OnMouseLeave (EventArgs e) 
    {
      base.OnMouseLeave (e);
    }
    
    protected override void OnMouseMove (MouseEventArgs e) 
    {
      base.OnMouseMove (e);
    }
    
    protected override void OnMouseUp (MouseEventArgs e) 
    {
      base.OnMouseUp (e);
    }
    
    protected override void OnPaint (PaintEventArgs e) 
    {
      base.OnPaint (e);
    }
    
    protected override void OnParentChanged (EventArgs e) 
    {
      base.OnParentChanged (e);
    }
    
    protected override void OnTextChanged (EventArgs e) 
    {
      base.OnTextChanged (e);
    }
    
    protected override void OnVisibleChanged (EventArgs e) 
    {
      base.OnVisibleChanged (e);
    }
    /// end of [methods for events]
    
    protected override void WndProc (ref Message m) 
    {
      base.WndProc (ref m);
    }
    
    /// --- ButtonBase.ButtonBaseAccessibleObject ---
    /// the class is not stubbed, cause it's only used for .NET framework
  }
}
www.java2v.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.