public class UIWindow extends UIView
NoIntrinsicMetric
Constructor and Description |
---|
UIWindow()
Constructs a default UIWindow object located at (0,0) with 0 weight and 0
height.
|
UIWindow(CGRect frame)
Constructs a UIWindow object initialized with the dimensions and position
specified in the frame parameter.
|
Modifier and Type | Method and Description |
---|---|
void |
addSubview(UIView subView)
Add the subview defined as parameter at this view's list of subviews.
|
CGPoint |
convertPointFromWindow(CGPoint point,
UIWindow window)
Adjusts a point's coordinates from a given window to this window.
|
CGPoint |
convertPointToWindow(CGPoint point,
UIWindow window)
Adjusts a point's coordinates defined in this window to another given
window.
|
CGRect |
convertRectFromWindow(CGRect point,
UIWindow window)
Adjusts a rectangle of a given window's coordinate system to the
coordinate system of this window.
|
CGRect |
convertRectToWindow(CGRect point,
UIWindow window)
Adjusts a rectangle of this window to the coordinate system of given
window.
|
void |
didAddSubview(UIView subview)
Informs this view that a subview was added.
|
UIView |
hitTest(CGPoint point,
UIEvent event)
Return the view that contains the point parameter and is remotest one in
the view hierarchy tree.
|
void |
makeKeyAndVisible()
Makes the receiver key window and moves it in front of any other windows
so that it is visible.
|
UIResponder |
nextResponder()
Returns the next responder of the response chain.
|
UIViewController |
rootViewController()
Returns the root view controller of this window.
|
void |
sendEvent(UIEvent event)
Dispatches events sent to the receiver by the UIApplication object to its
views.
|
void |
setRootViewController(UIViewController controller)
Sets the specified controller as root view controller of this window.
|
void |
willRemoveSubview(UIView subview)
Informs this view that a subview will be removed.
|
UIWindow |
window()
Returns this view's window.
|
accessibilityIdentifier, addConstraint, addConstraints, addGestureRecognizer, addLayoutGuide, alpha, animateWithDuration, animateWithDuration, animateWithDuration, areAnimationsEnabled, autoresizesSubviews, autoresizingMask, backgroundColor, bottomAnchor, bounds, bringSubviewToFront, center, centerXAnchor, centerYAnchor, clipsToBounds, constraints, contentCompressionResistancePriorityForAxis, contentHuggingPriorityForAxis, contentMode, convertPointFromView, convertPointToView, convertRectFromView, convertRectToView, didMoveToSuperview, didMoveToWindow, drawRect, frame, gestureRecognizers, heightAnchor, insertSubview, insetsLayoutMarginsFromSafeArea, intrinsicContentSize, invalidateIntrinsicContentSize, isHidden, isMultipleTouchEnabled, isOpaque, isUserInteractionEnabled, layer, layoutIfNeeded, layoutMargins, layoutMarginsDidChange, layoutMarginsGuide, layoutSubviews, leadingAnchor, leftAnchor, maskView, needsUpdateConstraints, overrideUserInterfaceStyle, pointInside, preservesSuperviewLayoutMargins, removeConstraint, removeConstraints, removeFromSuperview, removeGestureRecognizer, removeLayoutGuide, requiresConstraintBasedLayout, restorationIdentifier, rightAnchor, safeAreaInsets, safeAreaLayoutGuide, sendSubviewToBack, setAccessibilityIdentifier, setAlpha, setAnimationBeginsFromCurrentState, setAnimationCurve, setAnimationDelay, setAnimationDuration, setAnimationRepeatAutoreverses, setAnimationRepeatCount, setAnimationsEnabled, setAnimationStartDate, setAutoresizesSubviews, setAutoresizingMask, setBackgroundColor, setBounds, setCenter, setClearsContextBeforeDrawing, setClipsToBounds, setContentCompressionResistancePriority, setContentHuggingPriority, setContentMode, setFrame, setGestureRecognizers, setHidden, setInsetsLayoutMarginsFromSafeArea, setLayoutMargins, setMaskView, setMultipleTouchEnabled, setNeedsDisplay, setNeedsLayout, setNeedsUpdateConstraints, setOpaque, setOverrideUserInterfaceStyle, setPreservesSuperviewLayoutMargins, setRestorationIdentifier, setTag, setTintAdjustmentMode, setTintColor, setTransform, setTranslatesAutoresizingMaskIntoConstraints, setUserInteractionEnabled, sizeThatFits, sizeToFit, subviews, superview, tag, tintAdjustmentMode, tintColor, tintColorDidChange, topAnchor, toString, trailingAnchor, transform, transitionWithView, translatesAutoresizingMaskIntoConstraints, updateConstraints, updateConstraintsIfNeeded, userInterfaceLayoutDirection, viewForFirstBaselineLayout, viewForLastBaselineLayout, widthAnchor, willMoveToSuperview, willMoveToWindow
becomeFirstResponder, isFirstResponder, resignFirstResponder, touchesBegan, touchesCancelled, touchesEnded, touchesMoved
addObserver, observeValueForKeyPath, performSelector, performSelectorOnMainThread, release, removeObserver, removeObserver, retain, setValueForKey, setValueForUndefinedKey, valueForKey, valueForUndefinedKey
public UIWindow()
public UIWindow(CGRect frame)
frame
- CGRect that defines dimension and position of UIWindow.public UIResponder nextResponder()
UIResponder
nextResponder
in class UIView
public void addSubview(UIView subView)
UIView
addSubview
in class UIView
subView
- The subview that is added at this view's list of subviews.
This subview is displayed above the other subviews.public void setRootViewController(UIViewController controller)
controller
- The root view controller for the window.public UIViewController rootViewController()
public CGPoint convertPointToWindow(CGPoint point, UIWindow window)
point
- The point to be adjusted.window
- The destination window into whose coordinate system the
original point will be adjusted. If NULL, then it uses the logical
coordinate system of the screen as original.public CGPoint convertPointFromWindow(CGPoint point, UIWindow window)
point
- The point to be adjusted.window
- The original window that contains the point to be adjusted
to this window. If NULL, then it uses the logical coordinate system of
the screen as original.public CGRect convertRectToWindow(CGRect point, UIWindow window)
point
- The rectangle of this window.window
- The destination window to which the rectangle of this
window will be adjusted. If NULL,then it uses the logical coordinate
system of the screen as a destination.public CGRect convertRectFromWindow(CGRect point, UIWindow window)
point
- The original rectangle.window
- The original window that contains the rectangle to be
adjusted.If NULL, then it uses the logical coordinate system of the
screen as original.public void makeKeyAndVisible()
public void willRemoveSubview(UIView subview)
UIView
willRemoveSubview
in class UIView
subview
- The subview that will be removed.public void didAddSubview(UIView subview)
UIView
didAddSubview
in class UIView
subview
- The subview that was added to this view.public UIView hitTest(CGPoint point, UIEvent event)
UIView
public void sendEvent(UIEvent event)
event
- The event to process.Copyright © 2020. All rights reserved.