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

Side by Side Diff: Source/core/page/scrolling/ScrollingCoordinator.cpp

Issue 691863003: Add a setting to do frame scrolls through the root layer. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/page/EventHandler.cpp ('k') | Source/core/paint/BlockPainter.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) 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2011 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 919 matching lines...) Expand 10 before | Expand all | Expand 10 after
930 if (compositingState != PaintsIntoOwnBacking && compositingState != Pain tsIntoGroupedBacking) 930 if (compositingState != PaintsIntoOwnBacking && compositingState != Pain tsIntoGroupedBacking)
931 return true; 931 return true;
932 } 932 }
933 return false; 933 return false;
934 } 934 }
935 935
936 MainThreadScrollingReasons ScrollingCoordinator::mainThreadScrollingReasons() co nst 936 MainThreadScrollingReasons ScrollingCoordinator::mainThreadScrollingReasons() co nst
937 { 937 {
938 MainThreadScrollingReasons reasons = static_cast<MainThreadScrollingReasons> (0); 938 MainThreadScrollingReasons reasons = static_cast<MainThreadScrollingReasons> (0);
939 939
940 if (!m_page->settings().threadedScrollingEnabled()) 940 // FIXME: make threaded scrolling work correctly with rootLayerScrolls.
941 if (!m_page->settings().threadedScrollingEnabled() || m_page->settings().roo tLayerScrolls())
941 reasons |= ThreadedScrollingDisabled; 942 reasons |= ThreadedScrollingDisabled;
942 943
943 if (!m_page->mainFrame()->isLocalFrame()) 944 if (!m_page->mainFrame()->isLocalFrame())
944 return reasons; 945 return reasons;
945 FrameView* frameView = m_page->deprecatedLocalMainFrame()->view(); 946 FrameView* frameView = m_page->deprecatedLocalMainFrame()->view();
946 if (!frameView) 947 if (!frameView)
947 return reasons; 948 return reasons;
948 949
949 if (frameView->hasSlowRepaintObjects()) 950 if (frameView->hasSlowRepaintObjects())
950 reasons |= HasSlowRepaintObjects; 951 reasons |= HasSlowRepaintObjects;
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
984 bool frameIsScrollable = frameView && frameView->isScrollable(); 985 bool frameIsScrollable = frameView && frameView->isScrollable();
985 if (frameIsScrollable != m_wasFrameScrollable) 986 if (frameIsScrollable != m_wasFrameScrollable)
986 return true; 987 return true;
987 988
988 if (WebLayer* scrollLayer = frameView ? toWebLayer(frameView->layerForScroll ing()) : 0) 989 if (WebLayer* scrollLayer = frameView ? toWebLayer(frameView->layerForScroll ing()) : 0)
989 return blink::WebSize(frameView->contentsSize()) != scrollLayer->bounds( ); 990 return blink::WebSize(frameView->contentsSize()) != scrollLayer->bounds( );
990 return false; 991 return false;
991 } 992 }
992 993
993 } // namespace blink 994 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/page/EventHandler.cpp ('k') | Source/core/paint/BlockPainter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698