Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(92)

Side by Side Diff: third_party/WebKit/Source/platform/scroll/ScrollbarTheme.h

Issue 2467693002: Implement overlay scrollbar fade out for non-composited scrollers. (Closed)
Patch Set: sigh....git cl format Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 const PlatformMouseEvent&); 96 const PlatformMouseEvent&);
97 virtual bool shouldDragDocumentInsteadOfThumb(const ScrollbarThemeClient&, 97 virtual bool shouldDragDocumentInsteadOfThumb(const ScrollbarThemeClient&,
98 const PlatformMouseEvent&) { 98 const PlatformMouseEvent&) {
99 return false; 99 return false;
100 } 100 }
101 101
102 // The position of the thumb relative to the track. 102 // The position of the thumb relative to the track.
103 int thumbPosition(const ScrollbarThemeClient& scrollbar) { 103 int thumbPosition(const ScrollbarThemeClient& scrollbar) {
104 return thumbPosition(scrollbar, scrollbar.currentPos()); 104 return thumbPosition(scrollbar, scrollbar.currentPos());
105 } 105 }
106 virtual double overlayScrollbarFadeOutDelaySeconds() const;
107 virtual double overlayScrollbarFadeOutDurationSeconds() const;
106 // The position the thumb would have, relative to the track, at the specified 108 // The position the thumb would have, relative to the track, at the specified
107 // scroll position. 109 // scroll position.
108 virtual int thumbPosition(const ScrollbarThemeClient&, float scrollPosition); 110 virtual int thumbPosition(const ScrollbarThemeClient&, float scrollPosition);
109 // The length of the thumb along the axis of the scrollbar. 111 // The length of the thumb along the axis of the scrollbar.
110 virtual int thumbLength(const ScrollbarThemeClient&); 112 virtual int thumbLength(const ScrollbarThemeClient&);
111 // The position of the track relative to the scrollbar. 113 // The position of the track relative to the scrollbar.
112 virtual int trackPosition(const ScrollbarThemeClient&); 114 virtual int trackPosition(const ScrollbarThemeClient&);
113 // The length of the track along the axis of the scrollbar. 115 // The length of the track along the axis of the scrollbar.
114 virtual int trackLength(const ScrollbarThemeClient&); 116 virtual int trackLength(const ScrollbarThemeClient&);
115 // The opacity to be applied to the thumb. 117 // The opacity to be applied to the thumb.
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 static DisplayItem::Type trackPiecePartToDisplayItemType(ScrollbarPart); 180 static DisplayItem::Type trackPiecePartToDisplayItemType(ScrollbarPart);
179 181
180 private: 182 private:
181 static ScrollbarTheme& 183 static ScrollbarTheme&
182 nativeTheme(); // Must be implemented to return the correct theme subclass. 184 nativeTheme(); // Must be implemented to return the correct theme subclass.
183 static bool gMockScrollbarsEnabled; 185 static bool gMockScrollbarsEnabled;
184 }; 186 };
185 187
186 } // namespace blink 188 } // namespace blink
187 #endif 189 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/scroll/Scrollbar.cpp ('k') | third_party/WebKit/Source/platform/scroll/ScrollbarTheme.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698