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

Side by Side Diff: Source/core/testing/Internals.cpp

Issue 306413002: Rename Repaint to Paint Invalidation Part 2 (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase to master Created 6 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * Copyright (C) 2013 Apple Inc. All rights reserved. 3 * Copyright (C) 2013 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 1985 matching lines...) Expand 10 before | Expand all | Expand 10 after
1996 1996
1997 void Internals::startTrackingRepaints(Document* document, ExceptionState& except ionState) 1997 void Internals::startTrackingRepaints(Document* document, ExceptionState& except ionState)
1998 { 1998 {
1999 if (!document || !document->view()) { 1999 if (!document || !document->view()) {
2000 exceptionState.throwDOMException(InvalidAccessError, document ? "The doc ument's view cannot be retrieved." : "The document provided is invalid."); 2000 exceptionState.throwDOMException(InvalidAccessError, document ? "The doc ument's view cannot be retrieved." : "The document provided is invalid.");
2001 return; 2001 return;
2002 } 2002 }
2003 2003
2004 FrameView* frameView = document->view(); 2004 FrameView* frameView = document->view();
2005 frameView->updateLayoutAndStyleForPainting(); 2005 frameView->updateLayoutAndStyleForPainting();
2006 frameView->setTracksRepaints(true); 2006 frameView->setTracksPaintInvalidations(true);
2007 } 2007 }
2008 2008
2009 void Internals::stopTrackingRepaints(Document* document, ExceptionState& excepti onState) 2009 void Internals::stopTrackingRepaints(Document* document, ExceptionState& excepti onState)
2010 { 2010 {
2011 if (!document || !document->view()) { 2011 if (!document || !document->view()) {
2012 exceptionState.throwDOMException(InvalidAccessError, document ? "The doc ument's view cannot be retrieved." : "The document provided is invalid."); 2012 exceptionState.throwDOMException(InvalidAccessError, document ? "The doc ument's view cannot be retrieved." : "The document provided is invalid.");
2013 return; 2013 return;
2014 } 2014 }
2015 2015
2016 FrameView* frameView = document->view(); 2016 FrameView* frameView = document->view();
2017 frameView->updateLayoutAndStyleForPainting(); 2017 frameView->updateLayoutAndStyleForPainting();
2018 frameView->setTracksRepaints(false); 2018 frameView->setTracksPaintInvalidations(false);
2019 } 2019 }
2020 2020
2021 void Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(Except ionState& exceptionState) 2021 void Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(Except ionState& exceptionState)
2022 { 2022 {
2023 updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(0, exceptionState) ; 2023 updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(0, exceptionState) ;
2024 } 2024 }
2025 2025
2026 void Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(Node* node, ExceptionState& exceptionState) 2026 void Internals::updateLayoutIgnorePendingStylesheetsAndRunPostLayoutTasks(Node* node, ExceptionState& exceptionState)
2027 { 2027 {
2028 Document* document; 2028 Document* document;
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
2369 } else if (type == "none") { 2369 } else if (type == "none") {
2370 webtype = blink::ConnectionTypeNone; 2370 webtype = blink::ConnectionTypeNone;
2371 } else { 2371 } else {
2372 exceptionState.throwDOMException(NotFoundError, ExceptionMessages::faile dToEnumerate("connection type", type)); 2372 exceptionState.throwDOMException(NotFoundError, ExceptionMessages::faile dToEnumerate("connection type", type));
2373 return; 2373 return;
2374 } 2374 }
2375 networkStateNotifier().setWebConnectionTypeForTest(webtype); 2375 networkStateNotifier().setWebConnectionTypeForTest(webtype);
2376 } 2376 }
2377 2377
2378 } // namespace WebCore 2378 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698