using System;
using Quik.Media;

namespace Quik.PAL
{
    /// <summary>
    /// The primary primary platform abstraction interface for Quik hosts.
    /// </summary>
    public interface IQuikPlatform : IDisposable
    {
        /// <summary>
        /// The title of the application.
        /// </summary>
        string Title { get; set; }

        /// <summary>
        /// The default icon for the application.
        /// </summary>
        QImage Icon { get; set; }

        /// <summary>
        /// The event raised when an event is received.
        /// </summary>
        event EventHandler EventRaised;

        /// <summary>
        /// Create a window.
        /// </summary>
        /// <returns>The window instance.</returns>
        IQuikPort CreatePort();

        /// <summary>
        /// Raise the events that have been enqueued.
        /// </summary>
        /// <param name="block">True to block until a new event arrives.</param>
        void ProcessEvents(bool block);
    }
}