OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_CHILD_WEBSCROLLBARBEHAVIOR_IMPL_MAC_H_ | 5 #ifndef CONTENT_RENDERER_WEBSCROLLBARBEHAVIOR_IMPL_MAC_H_ |
6 #define CONTENT_CHILD_WEBSCROLLBARBEHAVIOR_IMPL_MAC_H_ | 6 #define CONTENT_RENDERER_WEBSCROLLBARBEHAVIOR_IMPL_MAC_H_ |
7 | 7 |
8 #include "third_party/WebKit/public/platform/WebScrollbarBehavior.h" | 8 #include "third_party/WebKit/public/platform/WebScrollbarBehavior.h" |
9 | 9 |
10 namespace content { | 10 namespace content { |
11 | 11 |
12 class WebScrollbarBehaviorImpl : public blink::WebScrollbarBehavior { | 12 class WebScrollbarBehaviorImpl : public blink::WebScrollbarBehavior { |
13 public: | 13 public: |
14 WebScrollbarBehaviorImpl(); | 14 WebScrollbarBehaviorImpl(); |
15 | 15 |
16 virtual bool shouldCenterOnThumb( | 16 virtual bool shouldCenterOnThumb( |
17 blink::WebScrollbarBehavior::Button mouseButton, | 17 blink::WebScrollbarBehavior::Button mouseButton, |
18 bool shiftKeyPressed, | 18 bool shiftKeyPressed, |
19 bool altKeyPressed); | 19 bool altKeyPressed); |
20 | 20 |
21 void set_jump_on_track_click(bool jump_on_track_click) { | 21 void set_jump_on_track_click(bool jump_on_track_click) { |
22 jump_on_track_click_ = jump_on_track_click; | 22 jump_on_track_click_ = jump_on_track_click; |
23 } | 23 } |
24 | 24 |
25 private: | 25 private: |
26 // The current value of AppleScrollerPagingBehavior from NSUserDefaults. | 26 // The current value of AppleScrollerPagingBehavior from NSUserDefaults. |
27 bool jump_on_track_click_; | 27 bool jump_on_track_click_; |
28 }; | 28 }; |
29 | 29 |
30 } // namespace content | 30 } // namespace content |
31 | 31 |
32 #endif // CONTENT_CHILD_WEBSCROLLBARBEHAVIOR_IMPL_MAC_H_ | 32 #endif // CONTENT_RENDERER_WEBSCROLLBARBEHAVIOR_IMPL_MAC_H_ |
OLD | NEW |