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

Side by Side Diff: Source/core/frame/FrameView.cpp

Issue 1147283002: Add ScrollDirectionPhysical enum in Scroll types. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed a conflict on EventHandler Created 5 years, 7 months 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
« no previous file with comments | « Source/core/frame/FrameView.h ('k') | Source/core/frame/RootFrameViewport.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
3 * 1999 Lars Knoll <knoll@kde.org> 3 * 1999 Lars Knoll <knoll@kde.org>
4 * 1999 Antti Koivisto <koivisto@kde.org> 4 * 1999 Antti Koivisto <koivisto@kde.org>
5 * 2000 Dirk Mueller <mueller@kde.org> 5 * 2000 Dirk Mueller <mueller@kde.org>
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved.
7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) 7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com)
8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
9 * Copyright (C) 2009 Google Inc. All rights reserved. 9 * Copyright (C) 2009 Google Inc. All rights reserved.
10 * 10 *
(...skipping 3250 matching lines...) Expand 10 before | Expand all | Expand 10 after
3261 void FrameView::setScrollOffset(const IntPoint& offset) 3261 void FrameView::setScrollOffset(const IntPoint& offset)
3262 { 3262 {
3263 scrollTo(DoublePoint(adjustScrollPositionWithinRange(offset))); 3263 scrollTo(DoublePoint(adjustScrollPositionWithinRange(offset)));
3264 } 3264 }
3265 3265
3266 void FrameView::setScrollOffset(const DoublePoint& offset) 3266 void FrameView::setScrollOffset(const DoublePoint& offset)
3267 { 3267 {
3268 scrollTo(adjustScrollPositionWithinRange(offset)); 3268 scrollTo(adjustScrollPositionWithinRange(offset));
3269 } 3269 }
3270 3270
3271 bool FrameView::scroll(ScrollDirection direction, ScrollGranularity granularity, float delta)
3272 {
3273 ScrollDirection physicalDirection =
3274 toPhysicalDirection(direction, isVerticalDocument(), isFlippedDocument() );
3275
3276 return ScrollableArea::scroll(physicalDirection, granularity, delta);
3277 }
3278
3279 void FrameView::windowResizerRectChanged() 3271 void FrameView::windowResizerRectChanged()
3280 { 3272 {
3281 updateScrollbars(scrollOffsetDouble()); 3273 updateScrollbars(scrollOffsetDouble());
3282 } 3274 }
3283 3275
3284 bool FrameView::hasOverlayScrollbars() const 3276 bool FrameView::hasOverlayScrollbars() const
3285 { 3277 {
3286 3278
3287 return (m_horizontalScrollbar && m_horizontalScrollbar->isOverlayScrollbar() ) 3279 return (m_horizontalScrollbar && m_horizontalScrollbar->isOverlayScrollbar() )
3288 || (m_verticalScrollbar && m_verticalScrollbar->isOverlayScrollbar()); 3280 || (m_verticalScrollbar && m_verticalScrollbar->isOverlayScrollbar());
(...skipping 784 matching lines...) Expand 10 before | Expand all | Expand 10 after
4073 4065
4074 if (!graphicsLayer) 4066 if (!graphicsLayer)
4075 return; 4067 return;
4076 4068
4077 DeprecatedPaintLayer::mapRectToPaintInvalidationBacking(localFrame->contentL ayoutObject(), paintInvalidationContainer, viewRect); 4069 DeprecatedPaintLayer::mapRectToPaintInvalidationBacking(localFrame->contentL ayoutObject(), paintInvalidationContainer, viewRect);
4078 4070
4079 graphicsLayerTimingRequests.add(graphicsLayer, Vector<std::pair<int64_t, Web Rect>>()).storedValue->value.append(std::make_pair(m_frame->frameID(), enclosing IntRect(viewRect))); 4071 graphicsLayerTimingRequests.add(graphicsLayer, Vector<std::pair<int64_t, Web Rect>>()).storedValue->value.append(std::make_pair(m_frame->frameID(), enclosing IntRect(viewRect)));
4080 } 4072 }
4081 4073
4082 } // namespace blink 4074 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/frame/FrameView.h ('k') | Source/core/frame/RootFrameViewport.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698