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

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

Issue 26110004: Defer the real work in updateCompositingLayers until it's really needed. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: almost there Created 7 years, 2 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 2273 matching lines...) Expand 10 before | Expand all | Expand 10 after
2284 if (!sharedContext) 2284 if (!sharedContext)
2285 return false; 2285 return false;
2286 sharedContext->extensions()->loseContextCHROMIUM(Extensions3D::GUILTY_CONTEX T_RESET_ARB, Extensions3D::INNOCENT_CONTEXT_RESET_ARB); 2286 sharedContext->extensions()->loseContextCHROMIUM(Extensions3D::GUILTY_CONTEX T_RESET_ARB, Extensions3D::INNOCENT_CONTEXT_RESET_ARB);
2287 // To prevent tests that call loseSharedGraphicsContext3D from being 2287 // To prevent tests that call loseSharedGraphicsContext3D from being
2288 // flaky, we call finish so that the context is guaranteed to be lost 2288 // flaky, we call finish so that the context is guaranteed to be lost
2289 // synchronously (i.e. before returning). 2289 // synchronously (i.e. before returning).
2290 sharedContext->finish(); 2290 sharedContext->finish();
2291 return true; 2291 return true;
2292 } 2292 }
2293 2293
2294 void Internals::forceCompositingUpdate(Document* document, ExceptionState& es)
2295 {
2296 if (!document || !document->renderView()) {
2297 es.throwUninformativeAndGenericDOMException(InvalidAccessError);
2298 return;
2299 }
2300
2301 document->updateLayout();
2302
2303 RenderView* view = document->renderView();
2304 if (view->compositor())
2305 view->compositor()->updateCompositingLayers(CompositingUpdateFinishAllDe ferredWork);
2294 } 2306 }
2307
2308 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698