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

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

Issue 139103009: If a compositing update is declared as needed, scheduleAnimation should be triggered. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: patch for landing, added crbug to fixme comment Created 6 years, 10 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
« no previous file with comments | « Source/core/testing/Internals.h ('k') | Source/core/testing/Internals.idl » ('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) 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 2305 matching lines...) Expand 10 before | Expand all | Expand 10 after
2316 return; 2316 return;
2317 } 2317 }
2318 2318
2319 document->updateLayout(); 2319 document->updateLayout();
2320 2320
2321 RenderView* view = document->renderView(); 2321 RenderView* view = document->renderView();
2322 if (view->compositor()) 2322 if (view->compositor())
2323 view->compositor()->updateCompositingLayers(); 2323 view->compositor()->updateCompositingLayers();
2324 } 2324 }
2325 2325
2326 bool Internals::isCompositorFramePending(Document* document, ExceptionState& exc eptionState)
2327 {
2328 if (!document || !document->renderView()) {
2329 exceptionState.throwDOMException(InvalidAccessError, document ? "The doc ument's render view cannot be retrieved." : "The document provided is invalid.") ;
2330 return false;
2331 }
2332
2333 return document->page()->chrome().client().isCompositorFramePending();
2334 }
2335
2326 void Internals::setZoomFactor(float factor) 2336 void Internals::setZoomFactor(float factor)
2327 { 2337 {
2328 frame()->setPageZoomFactor(factor); 2338 frame()->setPageZoomFactor(factor);
2329 } 2339 }
2330 2340
2331 void Internals::setShouldRevealPassword(Element* element, bool reveal, Exception State& exceptionState) 2341 void Internals::setShouldRevealPassword(Element* element, bool reveal, Exception State& exceptionState)
2332 { 2342 {
2333 if (!element || !element->hasTagName(inputTag)) { 2343 if (!element || !element->hasTagName(inputTag)) {
2334 exceptionState.throwUninformativeAndGenericDOMException(InvalidAccessErr or); 2344 exceptionState.throwUninformativeAndGenericDOMException(InvalidAccessErr or);
2335 return; 2345 return;
(...skipping 29 matching lines...) Expand all
2365 }; 2375 };
2366 2376
2367 } // namespace 2377 } // namespace
2368 2378
2369 ScriptPromise Internals::addOneToPromise(ExecutionContext* context, ScriptPromis e promise) 2379 ScriptPromise Internals::addOneToPromise(ExecutionContext* context, ScriptPromis e promise)
2370 { 2380 {
2371 return promise.then(AddOneFunction::create(context)); 2381 return promise.then(AddOneFunction::create(context));
2372 } 2382 }
2373 2383
2374 } 2384 }
OLDNEW
« no previous file with comments | « Source/core/testing/Internals.h ('k') | Source/core/testing/Internals.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698