1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef UI_APP_LIST_COCOA_SCROLL_VIEW_WITH_NO_SCROLLBARS_H_
6 #define UI_APP_LIST_COCOA_SCROLL_VIEW_WITH_NO_SCROLLBARS_H_
8 #include <Cocoa/Cocoa.h>
10 // Delegate to notify when a user interaction to scroll completes.
11 @protocol GestureScrollDelegate
13 // Called when a scroll gesture is observed, or when it completes.
14 - (void)userScrolling
:(BOOL
)isScrolling
;
18 // NSScrollView has a quirk when created programatically that causes gesture
19 // scrolling to fail if it does not have a scroll bar. This provides a scroll
20 // view using custom scrollers that are not visible.
21 @interface ScrollViewWithNoScrollbars
: NSScrollView
{
23 id
<GestureScrollDelegate
> delegate_
;
26 @
property(assign
, nonatomic
) id
<GestureScrollDelegate
> delegate
;
30 #endif // UI_APP_LIST_COCOA_SCROLL_VIEW_WITH_NO_SCROLLBARS_H_