/// <summary>
        /// Initializes a new instance of the <see cref="CalendarClientEventsBuilder"/> class.
        /// </summary>
        /// <param name="clientEvents">Client events of the calendar.</param>
        /// <param name="viewContext">The context of the View.</param>
        public CalendarClientEventsBuilder(CalendarClientEvents clientEvents, ViewContext viewContext)
        {
            Guard.IsNotNull(clientEvents, "clientEvents");
            Guard.IsNotNull(viewContext, "viewContext");

            this.clientEvents = clientEvents;
            this.viewContext = viewContext;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="CalendarClientEventsBuilder"/> class.
        /// </summary>
        /// <param name="clientEvents">Client events of the calendar.</param>
        /// <param name="viewContext">The context of the View.</param>
        public CalendarClientEventsBuilder(CalendarClientEvents clientEvents, ViewContext viewContext)
        {
            Guard.IsNotNull(clientEvents, "clientEvents");
            Guard.IsNotNull(viewContext, "viewContext");

            this.clientEvents = clientEvents;
            this.viewContext  = viewContext;
        }
Beispiel #3
0
        public Calendar(ViewContext viewContext, IClientSideObjectWriterFactory clientSideObjectWriterFactory, IUrlGenerator urlGenerator, ICalendarHtmlBuilderFactory rendererFactory)
            : base(viewContext, clientSideObjectWriterFactory)
        {
            UrlGenerator = urlGenerator;

            ScriptFileNames.AddRange(new[] { "telerik.common.js", "telerik.calendar.js" });

            ClientEvents = new CalendarClientEvents();

            SelectionSettings = new CalendarSelectionSettings { Dates = new List<DateTime>() };

            MinDate = new DateTime(1899, 12, 31);
            MaxDate = new DateTime(2100, 1, 1);
            Value = null;

            this.rendererFactory = rendererFactory;
        }
Beispiel #4
0
        public Calendar(ViewContext viewContext, IClientSideObjectWriterFactory clientSideObjectWriterFactory, IUrlGenerator urlGenerator, ICalendarHtmlBuilderFactory rendererFactory)
            : base(viewContext, clientSideObjectWriterFactory)
        {
            UrlGenerator = urlGenerator;

            ScriptFileNames.AddRange(new[] { "telerik.common.js", "telerik.calendar.js" });

            ClientEvents = new CalendarClientEvents();

            SelectionSettings = new CalendarSelectionSettings {
                Dates = new List <DateTime>()
            };

            MinDate = new DateTime(1899, 12, 31);
            MaxDate = new DateTime(2100, 1, 1);
            Value   = null;

            this.rendererFactory = rendererFactory;
        }