4 // Copyright (C) 2005, 2006, 2007, 2009 Apple Inc. All rights reserved.
10 #import <Foundation/Foundation.h>
12 #import <CoreGraphics/CoreGraphics.h>
14 #import "WAKAppKitStubs.h"
16 #import "WAKResponder.h"
19 #import "WKContentObservation.h"
24 kWAKWindowTilingModeNormal
,
25 kWAKWindowTilingModeMinimal
,
26 kWAKWindowTilingModePanning
,
27 kWAKWindowTilingModeZooming
,
28 kWAKWindowTilingModeDisabled
29 } WAKWindowTilingMode
;
31 @interface WAKWindow
: WAKResponder
35 // Create layer hosted window
36 - (id
)initWithLayer
:(CALayer
*)hostLayer
;
37 // Create unhosted window for manual painting
38 - (id
)initWithFrame
:(CGRect
)frame
;
40 - (void)setContentView
:(WAKView
*)aView
;
41 - (WAKView
*)contentView
;
43 - (WAKResponder
*)firstResponder
;
44 - (NSPoint
)convertBaseToScreen
:(NSPoint
)aPoint
;
45 - (NSPoint
)convertScreenToBase
:(NSPoint
)aPoint
;
46 - (void)endEditingFor
:(id
)anObject
;
48 - (GSEventRef
)currentEvent
;
50 - (NSSelectionDirection
)keyViewSelectionDirection
;
51 - (BOOL
)makeFirstResponder
:(NSResponder
*)aResponder
;
52 - (WKWindowRef
)_windowRef
;
53 - (void)setFrame
:(NSRect
)frameRect display
:(BOOL
)flag
;
54 - (void)sendGSEvent
:(id
)aGSEventRef
;
55 - (void)sendGSEvent
:(id
)aGSEventRef contentChange
:(WKContentChange
*)aContentChange
;
59 - (BOOL
)_needsToResetDragMargins
;
60 - (void)_setNeedsToResetDragMargins
:(BOOL
)flag
;
64 - (void)layoutTilesNow
;
65 - (void)setNeedsDisplay
;
66 - (void)setNeedsDisplayInRect
:(CGRect
)rect
;
68 - (void)setTilesOpaque
:(BOOL
)opaque
;
69 - (CGRect
)visibleRect
;
70 - (void)removeAllNonVisibleTiles
;
71 - (void)removeAllTiles
;
72 - (void)setTilingMode
:(WAKWindowTilingMode
)mode
;
73 - (WAKWindowTilingMode
)tilingMode
;
74 - (BOOL
)hasPendingDraw
;
76 - (BOOL
)useOrientationDependentFontAntialiasing
;
77 - (void)setUseOrientationDependentFontAntialiasing
:(BOOL
)aa
;
78 + (BOOL
)hasLandscapeOrientation
;
79 + (void)setOrientationProvider
:(id
)provider
;