zoukankan      html  css  js  c++  java
  • DateChooser源码RevealTransitionEditor.cs

    using System;
    using System.ComponentModel;
    using System.Design;
    using System.Drawing;
    using System.Drawing.Design;
    using System.Windows.Forms;
    using System.Windows.Forms.Design;

    namespace CNBlogs.DCT.THIN.Design
    {
     /// <summary>
     /// RevealTransitionEditor 的摘要说明。 
     /// </summary>
     public class RevealTransitionEditor:UITypeEditor
     {
      public RevealTransitionEditor()
      {
       
      }
      public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value)
      {
       if (provider != null)
       {
        IWindowsFormsEditorService service1 = (IWindowsFormsEditorService) provider.GetService(typeof(IWindowsFormsEditorService));
        if (service1 == null)
        {
         return value;
        }
        if (this.tranUI == null)
        {
         this.tranUI = new RevealTransitionUI();
        }
        this.tranUI.Start(service1, value);
        service1.DropDownControl(this.tranUI);
        value = this.tranUI.Value;
        this.tranUI.End();
       }
       return value;
      }

      public override UITypeEditorEditStyle GetEditStyle(ITypeDescriptorContext context)
      {
       return UITypeEditorEditStyle.DropDown;
      }


      // Fields
      private RevealTransitionUI tranUI;


      
      
     }
    }

  • 相关阅读:
    API
    API
    for in
    event flow
    object
    Report of program history
    正则表达式
    伪类与伪元素
    Position
    js学习之原型(补充)
  • 原文地址:https://www.cnblogs.com/think/p/170132.html
Copyright © 2011-2022 走看看