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

Unified Diff: third_party/WebKit/Source/platform/scroll/ScrollbarTestSuite.h

Issue 2590163004: Aura overlay scrollbars shouldn't invalidate thumb on scroll or enabled state. (Closed)
Patch Set: Nit Created 4 years 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/platform/scroll/ScrollbarTestSuite.h
diff --git a/third_party/WebKit/Source/platform/scroll/ScrollbarTestSuite.h b/third_party/WebKit/Source/platform/scroll/ScrollbarTestSuite.h
index a4789a58fc390fd3036d9b87bfcd061776fab193..d04bdf2e27858fec8316e342caef0ced2562915c 100644
--- a/third_party/WebKit/Source/platform/scroll/ScrollbarTestSuite.h
+++ b/third_party/WebKit/Source/platform/scroll/ScrollbarTestSuite.h
@@ -21,6 +21,11 @@ class MockScrollableArea : public GarbageCollectedFinalized<MockScrollableArea>,
USING_GARBAGE_COLLECTED_MIXIN(MockScrollableArea);
public:
+ // Public to allow using NiceMock.
jbroman 2016/12/22 15:21:00 Does protected not work? NiceMock<T> derives from
bokan 2016/12/22 16:10:55 Sure does. Done.
+ explicit MockScrollableArea() : m_maximumScrollOffset(ScrollOffset(0, 100)) {}
+ explicit MockScrollableArea(const ScrollOffset& offset)
+ : m_maximumScrollOffset(offset) {}
+
static MockScrollableArea* create() { return new MockScrollableArea(); }
static MockScrollableArea* create(const ScrollOffset& maximumScrollOffset) {
@@ -34,14 +39,14 @@ class MockScrollableArea : public GarbageCollectedFinalized<MockScrollableArea>,
MOCK_CONST_METHOD1(scrollSize, int(ScrollbarOrientation));
MOCK_CONST_METHOD0(isScrollCornerVisible, bool());
MOCK_CONST_METHOD0(scrollCornerRect, IntRect());
- MOCK_CONST_METHOD0(horizontalScrollbar, Scrollbar*());
- MOCK_CONST_METHOD0(verticalScrollbar, Scrollbar*());
MOCK_CONST_METHOD0(enclosingScrollableArea, ScrollableArea*());
MOCK_CONST_METHOD1(visibleContentRect, IntRect(IncludeScrollbarsInRect));
MOCK_CONST_METHOD0(contentsSize, IntSize());
MOCK_CONST_METHOD0(scrollableAreaBoundingBox, IntRect());
MOCK_CONST_METHOD0(layerForHorizontalScrollbar, GraphicsLayer*());
MOCK_CONST_METHOD0(layerForVerticalScrollbar, GraphicsLayer*());
+ MOCK_CONST_METHOD0(horizontalScrollbar, Scrollbar*());
+ MOCK_CONST_METHOD0(verticalScrollbar, Scrollbar*());
bool userInputScrollable(ScrollbarOrientation) const override { return true; }
bool scrollbarsCanBeActive() const override { return true; }
@@ -73,8 +78,6 @@ class MockScrollableArea : public GarbageCollectedFinalized<MockScrollableArea>,
m_maximumScrollOffset = maximumScrollOffset;
}
- explicit MockScrollableArea() : m_maximumScrollOffset(ScrollOffset(0, 100)) {}
-
ScrollOffset m_scrollOffset;
ScrollOffset m_maximumScrollOffset;
};

Powered by Google App Engine
This is Rietveld 408576698