Ejemplo n.º 1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="DSoft.UI.Calendar.Views.OSX.OSXEventView"/> class.
        /// </summary>
        /// <param name="Frame">Frame.</param>
        /// <param name="AnEvent">An event.</param>
        /// <param name="ViewType">View type.</param>
        public OSXEventView(RectangleF Frame, DSCalendarEvent AnEvent, DSEventType ViewType) : base(Frame, AnEvent, ViewType)
        {
            this.BackgroundColor = UIColor.Clear;

            mTitleLabel = new UILabel(RectangleF.Empty);
            mTitleLabel.BackgroundColor = UIColor.Clear;
            mTitleLabel.TextColor       = UIColor.Black;
            mTitleLabel.Font            = UIFont.SystemFontOfSize(12);
            this.AddSubview(mTitleLabel);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="DSoft.UI.Calendar.Views.Metro.MetroEventView"/> class.
        /// </summary>
        /// <param name="Frame">Frame.</param>
        /// <param name="AnEvent">An event.</param>
        /// <param name="ViewType">View type.</param>
        public MetroEventView(RectangleF Frame, DSCalendarEvent AnEvent, DSEventType ViewType) : base(Frame, AnEvent, ViewType)
        {
            this.BackgroundColor = UIColor.Clear;

            mTitleLabel = new UILabel(Rectangle.Empty);
            mTitleLabel.BackgroundColor  = UIColor.Clear;
            mTitleLabel.TextColor        = UIColor.White;
            mTitleLabel.TextAlignment    = UITextAlignment.Left;
            mTitleLabel.Font             = UIFont.SystemFontOfSize(14);
            mTitleLabel.AutoresizingMask = UIViewAutoresizing.FlexibleWidth | UIViewAutoresizing.FlexibleHeight;
            this.AddSubview(mTitleLabel);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Initialize the specified AnEvent and ViewType.
        /// </summary>
        /// <param name="AnEvent">An event.</param>
        /// <param name="ViewType">View type.</param>
        private void Initialize(DSCalendarEvent AnEvent, DSEventType ViewType)
        {
            this.Opaque        = false;
            this.ClipsToBounds = true;

            mEvent = AnEvent;
            mType  = ViewType;

            this.AutosizesSubviews = true;
            this.AutoresizingMask  = UIViewAutoresizing.FlexibleWidth;

            this.DoubleTap += () =>
            {
                if (this.Superview != null && this.Superview is DSCalendarEventsView)
                {
                    ((DSCalendarEventsView)this.Superview).DoubleTappedEvent(Event, this);
                }
            };
        }
Ejemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="DSoft.UI.Calendar.Views.DSEventView"/> class.
 /// </summary>
 /// <param name="Frame">Frame.</param>
 /// <param name="AnEvent">An event.</param>
 /// <param name="ViewType">View type.</param>
 public DSEventView(RectangleF Frame, DSCalendarEvent AnEvent, DSEventType ViewType) : base(Frame)
 {
     Initialize(AnEvent, ViewType);
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Get the EventView for the Event
 /// </summary>
 /// <returns>The view for event.</returns>
 /// <param name="Data">Data.</param>
 /// <param name="ViewType">View type.</param>
 public override DSEventView EventViewForEvent(DSCalendarEvent Data, DSEventType ViewType)
 {
     return(new Views.iOS.iOSEventView(RectangleF.Empty, Data, ViewType));
 }
Ejemplo n.º 6
0
 /// <summary>
 /// Get the EventView for the Event
 /// </summary>
 /// <returns>The view for event.</returns>
 /// <param name="Data">Data.</param>
 /// <param name="ViewType">View type.</param>
 public abstract DSEventView EventViewForEvent(DSCalendarEvent Data, DSEventType ViewType);