今天发现一件很恼火的事情

    作为一个人应该懂得尊重他人的劳动成果,对于技术人员同行成果更应该尊重!前几天在上看到了国内开发一套很不错的ASP.NETUI控件,说真的能做出这样一套控件真是让人所敬佩!在了解过程发现和以前看到的有点相似不过想不起来(在国内控件能做到在感观和使用上都认人叹为观止的厂商确实极少,可能我对这行业不了解)!没想到今天收到了ComponentArt的一封邮件:

ComponentArt  Hot Summer Pricing - plus Atlas Support &...  713 45KB

浏览了一下发很多控件和前两天看到有惊人的相似!于时对前两天看到的产生怀疑,于是用Reflector看了一下DLL;结果不用我说大家看下以下代码就知道了:

ComponentArt.Web.UI. Calendar:

[Designer(typeof(CalendarDesigner)), Guid("EA6708B1-1C69-43D0-AE63-CCFEBE180FCC"), LicenseProvider(typeof(RegistryFileLicenseProvider)), PersistChildren(false), ParseChildren(true)]

public sealed class Calendar : WebControl, IPostBackDataHandler

{

      // Events

      public event DayRenderEventHandler DayRender;

      public event SelectionChangedEventHandler SelectionChanged;

      public event VisibleDateChangedEventHandler VisibleDateChanged;

 

      // Methods

      static Calendar();

      public Calendar();

      private CalendarCellData CalculateCalendarCellData(CalendarCellInfo cellInfo);

      private string CalendarCellDataJavaScriptArray();

      private string CalendarCellDateId(int year, int month, int day, string suffix);

      protected override void ComponentArtRender(HtmlTextWriter output);

      private string ComposeCssClasses(string[] cssClassArray);

      private DateTime ConfinedVisibleDate(DateTime proposedVisibleDate);

      protected override void CreateChildControls();

      private DateTime CreateDate(int year, int month, int day);

      private int DaysInMonth(int year, int month);

      private void DetermineBrowserCapabilities();

      private CalendarDayCustomTemplate FindTemplateById(string sTemplateId);

      private void InstantiateTemplatedDays();

      protected override bool IsDownLevel();

      public bool LoadPostData(string postDataKey, NameValueCollection postCollection);

      protected override void LoadViewState(object savedState);

      private int MaxStringLength(string[] stringArray);

      protected override void OnInit(EventArgs e);

      protected override void OnLoad(EventArgs e);

      protected override void OnPreRender(EventArgs e);

      private void OnSelectionChanged(EventArgs e);

      private void OnVisibleDateChanged(EventArgs e);

      private void PopulateCalendarCellData(CalendarCellInfo[] cellInfoArray);

      public void RaisePostDataChangedEvent();

      public void ReloadTemplates();

      private void RenderDownLevelCalendar(HtmlTextWriter output);

      private void RenderDownLevelCalendarMonth(HtmlTextWriter output, int year, int month);

      private void RenderDownLevelCalendarMonths(HtmlTextWriter output);

      private void RenderDownLevelCalendarTitle(HtmlTextWriter output);

      internal void RenderDownLevelContent(HtmlTextWriter output);

      private void RenderDownLevelPicker(HtmlTextWriter output);

      private string ResolvePickerFormatString();

      protected override object SaveViewState();

      private int SymbolTokenLength(DateTimeFormatToken symbolToken);

      private int TokenLengthSum(DateTimeFormatToken[] tokens);

      private bool VerifyDates();

 

      // Properties

      public string[] AbbreviatedDayNames { get; set; }

      public string[] AbbreviatedMonthNames { get; set; }

      public bool AllowDaySelection { get; set; }

      public bool AllowMonthSelection { get; set; }

      public bool AllowMultipleSelection { get; set; }

      public bool AllowWeekSelection { get; set; }

      public string AMDesignator { get; set; }

      [DefaultValue(false)]

      public bool AutoPostBackOnSelectionChanged { get; set; }

      [DefaultValue(false)]

      public bool AutoPostBackOnVisibleDateChanged { get; set; }

      public string CalendarCssClass { get; set; }

      public string CalendarTitleCssClass { get; set; }

      public string CalendarTitleDateFormat { get; set; }

      public string CalendarTitleDateRangeSeparatorString { get; set; }

      public CalendarTitleType CalendarTitleType { get; set; }

      public int CellPadding { get; set; }

      public int CellSpacing { get; set; }

      [Category("Behavior"), Description("Client-side function to call after the Calendar control finishes a VisibleDate month swap.")]

      public string ClientSideOnAfterVisibleDateChanged { get; set; }

      [Description("Client-side function to call before the Calendar control starts a VisibleDate month swap."), Category("Behavior")]

      public string ClientSideOnBeforeVisibleDateChanged { get; set; }

      [Category("Behavior"), Description("Client-side function to call when the SelectedDates collection of the calendar changes.")]

      public string ClientSideOnSelectionChanged { get; set; }

      [Description("Client-side function to call when the VisibleDate of the calendar changes."), Category("Behavior")]

      public string ClientSideOnVisibleDateChanged { get; set; }

      [DefaultValue(true)]

      public bool CollapseOnSelect { get; set; }

      public CalendarControlType ControlType { get; set; }

      public CultureInfo Culture { set; }

      public int CultureId { set; }

      public string CultureName { set; }

      public CalendarDayCollection CustomDays { get; }

      public DateTimeFormatInfo DateTimeFormat { get; set; }

      public string DayActiveCssClass { get; set; }

      public string DayCssClass { get; set; }

      public string DayHeaderCssClass { get; set; }

      public string DayHoverCssClass { get; set; }

      public DayNameFormat DayNameFormat { get; set; }

      public string[] DayNames { get; set; }

      public DateCollection DisabledDates { get; }

      public string DisabledDayActiveCssClass { get; set; }

      public string DisabledDayCssClass { get; set; }

      public string DisabledDayHoverCssClass { get; set; }

      public FirstDayOfWeek FirstDayOfWeek { get; set; }

      [PersistenceMode(PersistenceMode.InnerProperty)]

      public ClientTemplate FooterClientTemplate { get; set; }

      [PersistenceMode(PersistenceMode.InnerProperty)]

      public ClientTemplate HeaderClientTemplate { get; set; }

      [Category("Support"), Description("Used as a prefix for all image URLs."), DefaultValue("")]

      public string ImagesBaseUrl { get; set; }

      public DateTime MaxDate { get; set; }

      public DateTime MinDate { get; set; }

      public int MonthColumns { get; set; }

      public string MonthCssClass { get; set; }

      public string[] MonthNames { get; set; }

      public int MonthPadding { get; set; }

      public int MonthRows { get; set; }

      public int MonthSpacing { get; set; }

      public string MonthTitleCssClass { get; set; }

      public int NextImageHeight { get; set; }

      public string NextImageUrl { get; set; }

      public int NextImageWidth { get; set; }

      public string NextPrevActiveCssClass { get; set; }

      public string NextPrevCssClass { get; set; }

      public string NextPrevHoverCssClass { get; set; }

      public string NextText { get; set; }

      public string OtherMonthDayActiveCssClass { get; set; }

      public string OtherMonthDayCssClass { get; set; }

      public string OtherMonthDayHoverCssClass { get; set; }

      public string OutOfRangeDayActiveCssClass { get; set; }

      public string OutOfRangeDayCssClass { get; set; }

      public string OutOfRangeDayHoverCssClass { get; set; }

      public string PickerCssClass { get; set; }

      public string PickerCustomFormat { get; set; }

      public DateTimeFormatType PickerFormat { get; set; }

      public string PMDesignator { get; set; }

      public CalendarPopUpType PopUp { get; set; }

      [Category("Animation"), DefaultValue(200), Description("The duration of the calendar pop-up animation, in milliseconds.")]

      public int PopUpCollapseDuration { get; set; }

      [DefaultValue(2), Category("Animation"), Description("The slide type to use for the calendar pop-up animation.")]

      public SlideType PopUpCollapseSlide { get; set; }

      [Description("The transition effect to use for the calendar pop-up animation."), DefaultValue(0), Category("Animation")]

      public TransitionType PopUpCollapseTransition { get; set; }

      [Category("Animation"), DefaultValue((string) null), Description("The custom transition filter to use for the calendar pop-up animation.")]

      public string PopUpCollapseTransitionCustomFilter { get; set; }

      [Category("Behavior"), Description("Client-side ID of the element to which this pop-up calendar is aligned.")]

      public string PopUpExpandControlId { get; set; }

      [Category("Behavior"), Description("Client-side ID of the element to which this pop-up calendar is aligned.")]

      public CalendarPopUpExpandDirection PopUpExpandDirection { get; set; }

      [Description("The duration of the calendar pop-up animation, in milliseconds."), Category("Animation"), DefaultValue(200)]

      public int PopUpExpandDuration { get; set; }

      [Category("Layout"), DefaultValue(0), Description("Offset along x-axis from pop-up calendar's normal expand position.")]

      public int PopUpExpandOffsetX { get; set; }

      [Category("Layout"), DefaultValue(0), Description("Offset along y-axis from pop-up calendar's normal expand position.")]

      public int PopUpExpandOffsetY { get; set; }

      [Category("Animation"), Description("The slide type to use for the calendar pop-up animation."), DefaultValue(2)]

      public SlideType PopUpExpandSlide { get; set; }

      [Description("The transition effect to use for the calendar pop-up animation."), DefaultValue(0), Category("Animation")]

      public TransitionType PopUpExpandTransition { get; set; }

      [Description("The custom transition filter to use for the calendar pop-up animation."), DefaultValue((string) null), Category("Animation")]

      public string PopUpExpandTransitionCustomFilter { get; set; }

      public int PrevImageHeight { get; set; }

      public string PrevImageUrl { get; set; }

      public int PrevImageWidth { get; set; }

      public string PrevText { get; set; }

      public DateTime SelectedDate { get; set; }

      public DateCollection SelectedDates { get; }

      public string SelectedDayActiveCssClass { get; set; }

      public string SelectedDayCssClass { get; set; }

      public string SelectedDayHoverCssClass { get; set; }

      public string SelectMonthActiveCssClass { get; set; }

      public string SelectMonthCssClass { get; set; }

      public string SelectMonthHoverCssClass { get; set; }

      public string SelectMonthText { get; set; }

      public string SelectWeekActiveCssClass { get; set; }

      public string SelectWeekCssClass { get; set; }

      public string SelectWeekHoverCssClass { get; set; }

      public string SelectWeekText { get; set; }

      public bool ShowCalendarTitle { get; set; }

      public bool ShowDayHeader { get; set; }

      public bool ShowGridLines { get; set; }

      public bool ShowMonthTitle { get; set; }

      public bool ShowNextPrev { get; set; }

      [Category("Animation"), DefaultValue(200), Description("The duration of the calendar swap animation, in milliseconds.")]

      public int SwapDuration { get; set; }

      [Description("The slide type to use for the calendar swap animation."), DefaultValue(3), Category("Animation")]

      public SlideType SwapSlide { get; set; }

      [Category("Animation"), DefaultValue(0), Description("The transition effect to use for the calendar swap animation.")]

      public TransitionType SwapTransition { get; set; }

      [DefaultValue((string) null), Description("The custom transition filter to use for the calendar swap animation."), Category("Animation")]

      public string SwapTransitionCustomFilter { get; set; }

      [PersistenceMode(PersistenceMode.InnerProperty), Description("Collection of template controls. "), Browsable(false)]

      public ControlCollection Templates { get; }

      public string TodayDayActiveCssClass { get; set; }

      public string TodayDayCssClass { get; set; }

      public string TodayDayHoverCssClass { get; set; }

      public DateTime TodaysDate { get; set; }

      [DefaultValue(true)]

      public bool ToggleSelectOnCtrlKey { get; set; }

      public bool UseServersTodaysDate { get; set; }

      public DateTime VisibleDate { get; set; }

      public int VisibleMonthColumn { get; set; }

      public int VisibleMonthRow { get; set; }

      public string WeekendDayActiveCssClass { get; set; }

      public string WeekendDayCssClass { get; set; }

      public string WeekendDayHoverCssClass { get; set; }

 

      // Fields

      private string[] _abbreviatedDayNames;

      private string[] _abbreviatedMonthNames;

      private string _amDesignator;

      private Hashtable _calendarCellData;

      private DateTimeFormatToken[] _calendarTitleTokens;

      private string _clientVarName;

      private CalendarDayCollection _customDaysCollection;

      private SortedList _customDaysList;

      private DateTimeFormatInfo _dateTimeFormat;

      private string[] _dayNames;

      private DayOfWeek _defaultFirstDayOfWeek;

      private DateCollection _disabledDatesCollection;

      private ArrayList _disabledDatesList;

      private ClientTemplate _footerClientTemplate;

      private string _footerClientTemplateString;

      private ClientTemplate _headerClientTemplate;

      private string _headerClientTemplateString;

      private bool _isCalendarUplevel;

      private bool _isPickerUplevel;

      private bool _isPopupUplevel;

      private string[] _monthNames;

      private DateTimeFormatToken[] _pickerTokens;

      private string _pmDesignator;

      private bool _selectedDatesChanged;

      private DateCollection _selectedDatesCollection;

      private SelectedDatesArrayList _selectedDatesList;

      private ControlCollection _templates;

      private DateTime _todaysDate;

      private bool _visibleDateChanged;

      private DayRenderEventHandler DayRender;

      public static readonly DateTime MaxDateTime;

      public static readonly DateTime MinDateTime;

      private SelectionChangedEventHandler SelectionChanged;

      private VisibleDateChangedEventHandler VisibleDateChanged;

 

      // Nested Types

      [StructLayout(LayoutKind.Sequential)]

      private struct CalendarCellData

      {

            public string Dormant;

            public string Hover;

            public string Active;

            public DateTime Date;

            public string TemplateInstanceId;

            public CalendarCellData(string dormant, string hover, string active, DateTime date, string templateInstanceId);

      }

 

      [StructLayout(LayoutKind.Sequential)]

      private struct CalendarCellInfo

      {

            public DateTime Date;

            public string Id;

            public bool IsSelected;

            public bool IsDisabled;

            public int Day;

            public int Month;

            public CalendarDay Custom;

            public CalendarCellInfo(DateTime date, string id, bool isSelected, bool isDisabled, int day, int month, CalendarDay custom);

      }

 

      public delegate void DayRenderEventHandler(object sender, CalendarDayRenderEventArgs e);

 

 

      private class SelectedDatesArrayList : ArrayList

      {

            // Methods

            public SelectedDatesArrayList(Calendar calendar);

            public override int Add(object value);

            public override void Clear();

            public override void Insert(int index, object value);

            public void Load(ArrayList arrayList);

            public override void RemoveAt(int index);

            private void VerifyDates();

 

            // Fields

            private Calendar calendar;

      }

 

      public delegate void SelectionChangedEventHandler(object sender, EventArgs e);

 

 

      public delegate void VisibleDateChangedEventHandler(object sender, EventArgs e);

 

}

 

 

 

xxxx.Web.UI. Calendar:

[Designer(typeof(CalendarDesigner)), ParseChildren(true), PersistChildren(false), Guid("EA6708B1-1C69-43D0-AE63-CCFEBE180FCC")]

public sealed class Calendar : WebControl, IPostBackDataHandler

{

      // Events

      public event DayRenderEventHandler DayRender;

      public event SelectionChangedEventHandler SelectionChanged;

      public event VisibleDateChangedEventHandler VisibleDateChanged;

 

      // Methods

      static Calendar();

      public Calendar();

      private CalendarCellData CalculateCalendarCellData(CalendarCellInfo cellInfo);

      private string CalendarCellDataJavaScriptArray();

      private string CalendarCellDateId(int year, int month, int day, string suffix);

      private string ComposeCssClasses(string[] cssClassArray);

      private DateTime ConfinedVisibleDate(DateTime proposedVisibleDate);

      protected override void CreateChildControls();

      private DateTime CreateDate(int year, int month, int day);

      private int DaysInMonth(int year, int month);

      private void DetermineBrowserCapabilities();

      private CalendarDayCustomTemplate FindTemplateById(string sTemplateId);

      private void InstantiateTemplatedDays();

      protected override bool IsDownLevel();

      public bool LoadPostData(string postDataKey, NameValueCollection postCollection);

      protected override void LoadViewState(object savedState);

      private int MaxStringLength(string[] stringArray);

      protected override void NickLeeRender(HtmlTextWriter output);

      protected override void OnInit(EventArgs e);

      protected override void OnLoad(EventArgs e);

      protected override void OnPreRender(EventArgs e);

      private void OnSelectionChanged(EventArgs e);

      private void OnVisibleDateChanged(EventArgs e);

      private void PopulateCalendarCellData(CalendarCellInfo[] cellInfoArray);

      public void RaisePostDataChangedEvent();

      public void ReloadTemplates();

      private void RenderDownLevelCalendar(HtmlTextWriter output);

      private void RenderDownLevelCalendarMonth(HtmlTextWriter output, int year, int month);

      private void RenderDownLevelCalendarMonths(HtmlTextWriter output);

      private void RenderDownLevelCalendarTitle(HtmlTextWriter output);

      internal void RenderDownLevelContent(HtmlTextWriter output);

      private void RenderDownLevelPicker(HtmlTextWriter output);

      private string ResolvePickerFormatString();

      protected override object SaveViewState();

      private int SymbolTokenLength(DateTimeFormatToken symbolToken);

      private int TokenLengthSum(DateTimeFormatToken[] tokens);

      private bool VerifyDates();

 

      // Properties

      public string[] AbbreviatedDayNames { get; set; }

      public string[] AbbreviatedMonthNames { get; set; }

      public bool AllowDaySelection { get; set; }

      public bool AllowMonthSelection { get; set; }

      public bool AllowMultipleSelection { get; set; }

      public bool AllowWeekSelection { get; set; }

      public string AMDesignator { get; set; }

      [DefaultValue(false)]

      public bool AutoPostBackOnSelectionChanged { get; set; }

      [DefaultValue(false)]

      public bool AutoPostBackOnVisibleDateChanged { get; set; }

      public string CalendarCssClass { get; set; }

      public string CalendarTitleCssClass { get; set; }

      public string CalendarTitleDateFormat { get; set; }

      public string CalendarTitleDateRangeSeparatorString { get; set; }

      public CalendarTitleType CalendarTitleType { get; set; }

      public int CellPadding { get; set; }

      public int CellSpacing { get; set; }

      [Description("Client-side function to call after the Calendar control finishes a VisibleDate month swap."), Category("Behavior")]

      public string ClientSideOnAfterVisibleDateChanged { get; set; }

      [Category("Behavior"), Description("Client-side function to call before the Calendar control starts a VisibleDate month swap.")]

      public string ClientSideOnBeforeVisibleDateChanged { get; set; }

      [Description("Client-side function to call when the SelectedDates collection of the calendar changes."), Category("Behavior")]

      public string ClientSideOnSelectionChanged { get; set; }

      [Category("Behavior"), Description("Client-side function to call when the VisibleDate of the calendar changes.")]

      public string ClientSideOnVisibleDateChanged { get; set; }

      [DefaultValue(true)]

      public bool CollapseOnSelect { get; set; }

      public CalendarControlType ControlType { get; set; }

      public CultureInfo Culture { set; }

      public int CultureId { set; }

      public string CultureName { set; }

      public CalendarDayCollection CustomDays { get; }

      public DateTimeFormatInfo DateTimeFormat { get; set; }

      public string DayActiveCssClass { get; set; }

      public string DayCssClass { get; set; }

      public string DayHeaderCssClass { get; set; }

      public string DayHoverCssClass { get; set; }

      public DayNameFormat DayNameFormat { get; set; }

      public string[] DayNames { get; set; }

      public DateCollection DisabledDates { get; }

      public string DisabledDayActiveCssClass { get; set; }

      public string DisabledDayCssClass { get; set; }

      public string DisabledDayHoverCssClass { get; set; }

      public FirstDayOfWeek FirstDayOfWeek { get; set; }

      [PersistenceMode(PersistenceMode.InnerProperty)]

      public ClientTemplate FooterClientTemplate { get; set; }

      [PersistenceMode(PersistenceMode.InnerProperty)]

      public ClientTemplate HeaderClientTemplate { get; set; }

      [DefaultValue(""), Description("Used as a prefix for all image URLs."), Category("Support")]

      public string ImagesBaseUrl { get; set; }

      public DateTime MaxDate { get; set; }

      public DateTime MinDate { get; set; }

      public int MonthColumns { get; set; }

      public string MonthCssClass { get; set; }

      public string[] MonthNames { get; set; }

      public int MonthPadding { get; set; }

      public int MonthRows { get; set; }

      public int MonthSpacing { get; set; }

      public string MonthTitleCssClass { get; set; }

      public int NextImageHeight { get; set; }

      public string NextImageUrl { get; set; }

      public int NextImageWidth { get; set; }

      public string NextPrevActiveCssClass { get; set; }

      public string NextPrevCssClass { get; set; }

      public string NextPrevHoverCssClass { get; set; }

      public string NextText { get; set; }

      public string OtherMonthDayActiveCssClass { get; set; }

      public string OtherMonthDayCssClass { get; set; }

      public string OtherMonthDayHoverCssClass { get; set; }

      public string OutOfRangeDayActiveCssClass { get; set; }

      public string OutOfRangeDayCssClass { get; set; }

      public string OutOfRangeDayHoverCssClass { get; set; }

      public string PickerCssClass { get; set; }

      public string PickerCustomFormat { get; set; }

      public DateTimeFormatType PickerFormat { get; set; }

      public string PMDesignator { get; set; }

      public CalendarPopUpType PopUp { get; set; }

      [Description("The duration of the calendar pop-up animation, in milliseconds."), DefaultValue(200), Category("Animation")]

      public int PopUpCollapseDuration { get; set; }

      [DefaultValue(2), Category("Animation"), Description("The slide type to use for the calendar pop-up animation.")]

      public SlideType PopUpCollapseSlide { get; set; }

      [Category("Animation"), DefaultValue(0), Description("The transition effect to use for the calendar pop-up animation.")]

      public TransitionType PopUpCollapseTransition { get; set; }

      [Description("The custom transition filter to use for the calendar pop-up animation."), Category("Animation"), DefaultValue((string) null)]

      public string PopUpCollapseTransitionCustomFilter { get; set; }

      [Description("Client-side ID of the element to which this pop-up calendar is aligned."), Category("Behavior")]

      public string PopUpExpandControlId { get; set; }

      [Category("Behavior"), Description("Client-side ID of the element to which this pop-up calendar is aligned.")]

      public CalendarPopUpExpandDirection PopUpExpandDirection { get; set; }

      [Category("Animation"), Description("The duration of the calendar pop-up animation, in milliseconds."), DefaultValue(200)]

      public int PopUpExpandDuration { get; set; }

      [DefaultValue(0), Category("Layout"), Description("Offset along x-axis from pop-up calendar's normal expand position.")]

      public int PopUpExpandOffsetX { get; set; }

      [Description("Offset along y-axis from pop-up calendar's normal expand position."), DefaultValue(0), Category("Layout")]

      public int PopUpExpandOffsetY { get; set; }

      [Description("The slide type to use for the calendar pop-up animation."), DefaultValue(2), Category("Animation")]

      public SlideType PopUpExpandSlide { get; set; }

      [DefaultValue(0), Description("The transition effect to use for the calendar pop-up animation."), Category("Animation")]

      public TransitionType PopUpExpandTransition { get; set; }

      [DefaultValue((string) null), Description("The custom transition filter to use for the calendar pop-up animation."), Category("Animation")]

      public string PopUpExpandTransitionCustomFilter { get; set; }

      public int PrevImageHeight { get; set; }

      public string PrevImageUrl { get; set; }

      public int PrevImageWidth { get; set; }

      public string PrevText { get; set; }

      public DateTime SelectedDate { get; set; }

      public DateCollection SelectedDates { get; }

      public string SelectedDayActiveCssClass { get; set; }

      public string SelectedDayCssClass { get; set; }

      public string SelectedDayHoverCssClass { get; set; }

      public string SelectMonthActiveCssClass { get; set; }

      public string SelectMonthCssClass { get; set; }

      public string SelectMonthHoverCssClass { get; set; }

      public string SelectMonthText { get; set; }

      public string SelectWeekActiveCssClass { get; set; }

      public string SelectWeekCssClass { get; set; }

      public string SelectWeekHoverCssClass { get; set; }

      public string SelectWeekText { get; set; }

      public bool ShowCalendarTitle { get; set; }

      public bool ShowDayHeader { get; set; }

      public bool ShowGridLines { get; set; }

      public bool ShowMonthTitle { get; set; }

      public bool ShowNextPrev { get; set; }

      [DefaultValue(200), Description("The duration of the calendar swap animation, in milliseconds."), Category("Animation")]

      public int SwapDuration { get; set; }

      [DefaultValue(3), Description("The slide type to use for the calendar swap animation."), Category("Animation")]

      public SlideType SwapSlide { get; set; }

      [Description("The transition effect to use for the calendar swap animation."), Category("Animation"), DefaultValue(0)]

      public TransitionType SwapTransition { get; set; }

      [Description("The custom transition filter to use for the calendar swap animation."), DefaultValue((string) null), Category("Animation")]

      public string SwapTransitionCustomFilter { get; set; }

      [PersistenceMode(PersistenceMode.InnerProperty), Browsable(false), Description("Collection of template controls. ")]

      public ControlCollection Templates { get; }

      public string TodayDayActiveCssClass { get; set; }

      public string TodayDayCssClass { get; set; }

      public string TodayDayHoverCssClass { get; set; }

      public DateTime TodaysDate { get; set; }

      [DefaultValue(true)]

      public bool ToggleSelectOnCtrlKey { get; set; }

      public bool UseServersTodaysDate { get; set; }

      public DateTime VisibleDate { get; set; }

      public int VisibleMonthColumn { get; set; }

      public int VisibleMonthRow { get; set; }

      public string WeekendDayActiveCssClass { get; set; }

      public string WeekendDayCssClass { get; set; }

      public string WeekendDayHoverCssClass { get; set; }

 

      // Fields

      private string[] _abbreviatedDayNames;

      private string[] _abbreviatedMonthNames;

      private string _amDesignator;

      private Hashtable _calendarCellData;

      private DateTimeFormatToken[] _calendarTitleTokens;

      private string _clientVarName;

      private CalendarDayCollection _customDaysCollection;

      private SortedList _customDaysList;

      private DateTimeFormatInfo _dateTimeFormat;

      private string[] _dayNames;

      private DayOfWeek _defaultFirstDayOfWeek;

      private DateCollection _disabledDatesCollection;

      private ArrayList _disabledDatesList;

      private ClientTemplate _footerClientTemplate;

      private string _footerClientTemplateString;

      private ClientTemplate _headerClientTemplate;

      private string _headerClientTemplateString;

      private bool _isCalendarUplevel;

      private bool _isPickerUplevel;

      private bool _isPopupUplevel;

      private string[] _monthNames;

      private DateTimeFormatToken[] _pickerTokens;

      private string _pmDesignator;

      private bool _selectedDatesChanged;

      private DateCollection _selectedDatesCollection;

      private SelectedDatesArrayList _selectedDatesList;

      private ControlCollection _templates;

      private DateTime _todaysDate;

      private bool _visibleDateChanged;

      private DayRenderEventHandler DayRender;

      public static readonly DateTime MaxDateTime;

      public static readonly DateTime MinDateTime;

      private SelectionChangedEventHandler SelectionChanged;

      private VisibleDateChangedEventHandler VisibleDateChanged;

 

      // Nested Types

      [StructLayout(LayoutKind.Sequential)]

      private struct CalendarCellData

      {

            public string Dormant;

            public string Hover;

            public string Active;

            public DateTime Date;

            public string TemplateInstanceId;

            public CalendarCellData(string dormant, string hover, string active, DateTime date, string templateInstanceId);

      }

 

      [StructLayout(LayoutKind.Sequential)]

      private struct CalendarCellInfo

      {

            public DateTime Date;

            public string Id;

            public bool IsSelected;

            public bool IsDisabled;

            public int Day;

            public int Month;

            public CalendarDay Custom;

            public CalendarCellInfo(DateTime date, string id, bool isSelected, bool isDisabled, int day, int month, CalendarDay custom);

      }

 

      public delegate void DayRenderEventHandler(object sender, CalendarDayRenderEventArgs e);

 

 

      private class SelectedDatesArrayList : ArrayList

      {

            // Methods

            public SelectedDatesArrayList(Calendar calendar);

            public override int Add(object value);

            public override void Clear();

            public override void Insert(int index, object value);

            public void Load(ArrayList arrayList);

            public override void RemoveAt(int index);

            private void VerifyDates();

 

            // Fields

            private Calendar calendar;

      }

 

      public delegate void SelectionChangedEventHandler(object sender, EventArgs e);

 

 

      public delegate void VisibleDateChangedEventHandler(object sender, EventArgs e);

 

}

 

看完后都不想再看其他控件了只能唉!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

要是我就把private部分混淆之后再发布.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值