summaryrefslogtreecommitdiff
path: root/CocoaSharp/UIKit/UIWindow.cs
blob: d05f0e93c007f69c93a6c75117757431fe60ca26 (plain)
1
using ObjectiveC;
using System;
using SharpSwift.Attributes;
using System.Collections.Generic;
using Foundation;
using CoreGraphics;

namespace UIKit
{
    /// <summary>
    /// The UIWindow class defines an object known as a window that manages and coordinates the views an app displays on a device screen. Unless an app can display content on an external device screen, an app has only one window.
    /// </summary>
    /// <see cref="https://developer.apple.com/library/prerelease/ios/documentation/UIKit/Reference/UIWindow_Class/index.html#//apple_ref/occ/cl/UIWindow"/>
    [iOSVersion(2)]
    public class UIWindow : UIView//, AnyObject, NSCoding, NSObjectProtocol, Reflectable, UIAccessibilityIdentification, UIAppearance, UIAppearanceContainer, UICoordinateSpace, UIDynamicItem, UITraitEnvironment
    {
        public UIWindow() { }
        /// <summary>
        /// Makes the receiver the key window and visible.
        /// </summary>
        [iOSVersion(2)]
        [Export("makeKeyAndVisible")]
        public virtual void MakeKeyAndVisible() {  }
        
        /// <summary>
        /// Invoked automatically to inform the receiver that it has become the key window; never invoke this method directly.
        /// </summary>
        [iOSVersion(2)]
        [Export("becomeKeyWindow")]
        public virtual void BecomeKeyWindow() {  }
        
        /// <summary>
        /// Makes the receiver the main window.
        /// </summary>
        [iOSVersion(2)]
        [Export("makeKeyWindow")]
        public virtual void MakeKeyWindow() {  }
        
        /// <summary>
        /// Invoked automatically when the window resigns key window status; never invoke this method directly.
        /// </summary>
        [iOSVersion(2)]
        [Export("resignKeyWindow")]
        public virtual void ResignKeyWindow() {  }
        
        /// <summary>
        /// Converts a point from the receiver’s coordinate system to that of another window.
        /// </summary>
        /// <param name="point">A point specifying a location in the logical coordinate system of the receiver.</param>
        /// <param name="toWindow">The window into whose coordinate system point is to be converted. If nil, this method converts the point to the logical coordinate system of the screen, which is measured in points.</param>
        [iOSVersion(2)]
        [Export("convertPoint")]
        public virtual CGPoint ConvertPoint(CGPoint point, UIWindow toWindow) { return default(CGPoint); }
        
        /// <summary>
        /// Converts a point from the coordinate system of a given window to that of the receiver.
        /// </summary>
        /// <param name="point">A point specifying a location in the coordinate system of window.</param>
        /// <param name="fromWindow">The window with point in its coordinate system. If nil, this method converts the point from the logical coordinate system of the screen, which is measured in points.</param>
        /// <param name="NAME_YOUR_PARAMS">DO NOT USE THIS PARAMETER - Instead make sure to name the parameters you're using.</param>
        [iOSVersion(2)]
        [Export("convertPoint")]
        [IgnoreParameter("NAME_YOUR_PARAMS")]
        public virtual CGPoint ConvertPoint(CGPoint point, UIWindow fromWindow, bool NAME_YOUR_PARAMS = false) { return default(CGPoint); }
        
        /// <summary>
        /// Converts a rectangle from the receiver’s coordinate system to that of another window.
        /// </summary>
        /// <param name="rect">A rectangle in the receiver's coordinate system.</param>
        /// <param name="toWindow">The window that is the target of the conversion operation. If nil, this method instead converts the rectangle to the logical coordinate system of the screen, which is measured in points.</param>
        [iOSVersion(2)]
        [Export("convertRect")]
        public virtual CGRect ConvertRect(CGRect rect, UIWindow toWindow) { return default(CGRect); }
        
        /// <summary>
        /// Converts a rectangle from the coordinate system of another window to that of the receiver.
        /// </summary>
        /// <param name="rect">The rectangle in the window's coordinate system.</param>
        /// <param name="fromWindow">The window with rect in its coordinate system. If nil, this method instead converts the rectangle from the logical coordinate system of the screen, which is measured in points.</param>
        /// <param name="NAME_YOUR_PARAMS">DO NOT USE THIS PARAMETER - Instead make sure to name the parameters you're using.</param>
        [iOSVersion(2)]
        [Export("convertRect")]
        [IgnoreParameter("NAME_YOUR_PARAMS")]
        public virtual CGRect ConvertRect(CGRect rect, UIWindow fromWindow, bool NAME_YOUR_PARAMS = false) { return default(CGRect); }
        
        /// <summary>
        /// Dispatches events sent to the receiver by the UIApplication object to its views.
        /// </summary>
        /// <param name="event">The event to process.</param>
        [iOSVersion(2)]
        [Export("sendEvent")]
        public virtual void SendEvent(UIEvent @event) {  }
        
        /// <summary>
        /// The receiver’s window level.
        /// </summary>
        [iOSVersion(2)]
        [Export("windowLevel")]
        public UIWindowLevel WindowLevel { get; set; }
        
        /// <summary>
        /// The screen on which the window is currently displayed.
        /// </summary>
        [iOSVersion(3.2)]
        [Export("screen")]
        public UIScreen Screen { get; set; }
        
        /// <summary>
        /// The root view controller for the window.
        /// </summary>
        [iOSVersion(4)]
        [Export("rootViewController")]
        public UIViewController RootViewController { get; set; }
        
        /// <summary>
        /// A Boolean value that indicates whether the receiver is the key window for the application. (read-only)
        /// </summary>
        [iOSVersion(2)]
        [Export("keyWindow")]
        public bool KeyWindow { get; private set; }
    }
    /// <summary>
    /// The positioning of windows relative to each other.
    /// </summary>
    [iOSVersion(2)]
    public struct UIWindowLevel
    {
        static public implicit operator UIWindowLevel(CGFloat value)
        {
            return default(UIWindowLevel);
        }
        static public implicit operator CGFloat(UIWindowLevel value)
        {
            return default(CGFloat);
        }
    }
    /// <summary>
    /// The notification object is the window object that has become visible. This notification does not contain a userInfo dictionary.
    /// </summary>
    [iOSVersion(2)]
    public class UIWindowDidBecomeVisibleNotification : NSNotification
    {
        public UIWindowDidBecomeVisibleNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is the window object that has become hidden. This notification does not contain a userInfo dictionary.
    /// </summary>
    [iOSVersion(2)]
    public class UIWindowDidBecomeHiddenNotification : NSNotification
    {
        public UIWindowDidBecomeHiddenNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is the window object that has become key. This notification does not contain a userInfo dictionary.
    /// </summary>
    [iOSVersion(2)]
    public class UIWindowDidBecomeKeyNotification : NSNotification
    {
        public UIWindowDidBecomeKeyNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is the window object that has resigned its main window status. This notification does not contain a userInfo dictionary.
    /// </summary>
    [iOSVersion(2)]
    public class UIWindowDidResignKeyNotification : NSNotification
    {
        public UIWindowDidResignKeyNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is nil. The userInfo dictionary contains information about the keyboard. Use the keys described in Keyboard Notification User Info Keys to get the location and size of the keyboard from the userInfo dictionary.
    /// </summary>
    [iOSVersion(2)]
    public class UIKeyboardWillShowNotification : NSNotification
    {
        public UIKeyboardWillShowNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is nil. The userInfo dictionary contains information about the keyboard. Use the keys described in Keyboard Notification User Info Keys to get the location and size of the keyboard from the userInfo dictionary.
    /// </summary>
    [iOSVersion(2)]
    public class UIKeyboardDidShowNotification : NSNotification
    {
        public UIKeyboardDidShowNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is nil. The userInfo dictionary contains information about the keyboard. Use the keys described in Keyboard Notification User Info Keys to get the location and size of the keyboard from the userInfo dictionary.
    /// </summary>
    [iOSVersion(2)]
    public class UIKeyboardWillHideNotification : NSNotification
    {
        public UIKeyboardWillHideNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is nil. The userInfo dictionary contains information about the keyboard. Use the keys described in Keyboard Notification User Info Keys to get the location and size of the keyboard from the userInfo dictionary.
    /// </summary>
    [iOSVersion(2)]
    public class UIKeyboardDidHideNotification : NSNotification
    {
        public UIKeyboardDidHideNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is nil. The userInfo dictionary contains information about the keyboard. Use the keys described in Keyboard Notification User Info Keys to get the location and size of the keyboard from the userInfo dictionary.
    /// </summary>
    [iOSVersion(5)]
    public class UIKeyboardWillChangeFrameNotification : NSNotification
    {
        public UIKeyboardWillChangeFrameNotification() : base("", null) { }
    }
    /// <summary>
    /// The notification object is nil. The userInfo dictionary contains information about the keyboard. Use the keys described in Keyboard Notification User Info Keys to get the location and size of the keyboard from the userInfo dictionary.
    /// </summary>
    [iOSVersion(5)]
    public class UIKeyboardDidChangeFrameNotification : NSNotification
    {
        public UIKeyboardDidChangeFrameNotification() : base("", null) { }
    }
}
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback