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

Side by Side Diff: Source/core/layout/LayoutBox.cpp

Issue 1161713004: Rename ScrollableArea::scroll to userScroll (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed comment Created 5 years, 6 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/RootFrameViewportTest.cpp ('k') | Source/core/page/EventHandler.cpp » ('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) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com)
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com)
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed.
7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 689 matching lines...) Expand 10 before | Expand all | Expand 10 after
700 } 700 }
701 701
702 bool LayoutBox::scroll(ScrollDirectionPhysical direction, ScrollGranularity gran ularity, float delta) 702 bool LayoutBox::scroll(ScrollDirectionPhysical direction, ScrollGranularity gran ularity, float delta)
703 { 703 {
704 // Presumably the same issue as in setScrollTop. See crbug.com/343132. 704 // Presumably the same issue as in setScrollTop. See crbug.com/343132.
705 DisableCompositingQueryAsserts disabler; 705 DisableCompositingQueryAsserts disabler;
706 706
707 if (!layer() || !layer()->scrollableArea()) 707 if (!layer() || !layer()->scrollableArea())
708 return false; 708 return false;
709 709
710 return layer()->scrollableArea()->scroll(direction, granularity, delta); 710 return layer()->scrollableArea()->userScroll(direction, granularity, delta);
711 } 711 }
712 712
713 bool LayoutBox::canBeScrolledAndHasScrollableArea() const 713 bool LayoutBox::canBeScrolledAndHasScrollableArea() const
714 { 714 {
715 return canBeProgramaticallyScrolled() && (pixelSnappedScrollHeight() != pixe lSnappedClientHeight() || pixelSnappedScrollWidth() != pixelSnappedClientWidth() ); 715 return canBeProgramaticallyScrolled() && (pixelSnappedScrollHeight() != pixe lSnappedClientHeight() || pixelSnappedScrollWidth() != pixelSnappedClientWidth() );
716 } 716 }
717 717
718 bool LayoutBox::canBeProgramaticallyScrolled() const 718 bool LayoutBox::canBeProgramaticallyScrolled() const
719 { 719 {
720 Node* node = this->node(); 720 Node* node = this->node();
(...skipping 4100 matching lines...) Expand 10 before | Expand all | Expand 10 after
4821 bool LayoutBox::canRenderBorderImage() const 4821 bool LayoutBox::canRenderBorderImage() const
4822 { 4822 {
4823 if (!style()->hasBorder()) 4823 if (!style()->hasBorder())
4824 return false; 4824 return false;
4825 4825
4826 StyleImage* borderImage = style()->borderImage().image(); 4826 StyleImage* borderImage = style()->borderImage().image();
4827 return borderImage && borderImage->canRender(*this, style()->effectiveZoom() ) && borderImage->isLoaded(); 4827 return borderImage && borderImage->canRender(*this, style()->effectiveZoom() ) && borderImage->isLoaded();
4828 } 4828 }
4829 4829
4830 } // namespace blink 4830 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/frame/RootFrameViewportTest.cpp ('k') | Source/core/page/EventHandler.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698