18e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project/*
2dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * Copyright (C) 2005, 2008, 2010 Apple Inc. All rights reserved.
38e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project *
48e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * Redistribution and use in source and binary forms, with or without
58e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * modification, are permitted provided that the following conditions
68e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * are met:
7dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * 1. Redistributions of source code must retain the above copyright
8dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block *    notice, this list of conditions and the following disclaimer.
9dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * 2. Redistributions in binary form must reproduce the above copyright
10dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block *    notice, this list of conditions and the following disclaimer in the
11dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block *    documentation and/or other materials provided with the distribution.
128e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project *
13dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
14dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
15dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
16dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
17dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
18dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
19dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
20dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
21dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
22dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
23dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block * THE POSSIBILITY OF SUCH DAMAGE.
248e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project */
258e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project
268e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project// This is a Private header (containing SPI), despite the fact that its name
278e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project// does not contain the word Private.
288e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project
29dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block#import <AppKit/NSScrollView.h>
308e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project
318e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project// FIXME: <rdar://problem/5898985> Mail currently expects this header to define WebCoreScrollbarAlwaysOn.
328e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Projectextern const int WebCoreScrollbarAlwaysOn;
338e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project
34dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Blockstruct WebDynamicScrollBarsViewPrivate;
358e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project@interface WebDynamicScrollBarsView : NSScrollView {
36dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block@private
37dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block    struct WebDynamicScrollBarsViewPrivate *_private;
38dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block
39dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block#ifndef __OBJC2__
40dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block    // We need to pad the class out to its former size.  See <rdar://problem/7814899> for more information.
41dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block    char padding[16];
42dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block#endif
438e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project}
44cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block
45cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block// This was originally added for Safari's benefit, but Safari has not used it for a long time.
46cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block// Perhaps it can be removed.
47cac0f67c402d107cdb10971b95719e2ff9c7c76bSteve Block- (void)setAllowsHorizontalScrolling:(BOOL)flag;
48dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block
49dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block// Determines whether the scrollers should be drawn outside of the content (as in normal scroll views)
50dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block// or should overlap the content.
51dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block- (void)setAllowsScrollersToOverlapContent:(BOOL)flag;
52dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block
53dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block// These methods hide the scrollers in a way that does not prevent scrolling.
54dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block- (void)setAlwaysHideHorizontalScroller:(BOOL)flag;
55dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block- (void)setAlwaysHideVerticalScroller:(BOOL)flag;
56dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block
57dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block// These methods return YES if the scrollers are visible, or if the only reason that they are not
58dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block// visible is that they have been suppressed by setAlwaysHideHorizontal/VerticalScroller:.
59dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block- (BOOL)horizontalScrollingAllowed;
60dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block- (BOOL)verticalScrollingAllowed;
618e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project@end
62