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

Side by Side Diff: Source/core/dom/Element.cpp

Issue 23874019: Web Animations CSS: Start running animations on the compositor (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Cleanup isRunning* and shouldCompositeForAnimation Created 7 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
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) 2001 Peter Kelly (pmk@post.com) 4 * (C) 2001 Peter Kelly (pmk@post.com)
5 * (C) 2001 Dirk Mueller (mueller@kde.org) 5 * (C) 2001 Dirk Mueller (mueller@kde.org)
6 * (C) 2007 David Smith (catfish.man@gmail.com) 6 * (C) 2007 David Smith (catfish.man@gmail.com)
7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc. All rights reserved. 7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc. All rights reserved.
8 * (C) 2007 Eric Seidel (eric@webkit.org) 8 * (C) 2007 Eric Seidel (eric@webkit.org)
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 1416 matching lines...) Expand 10 before | Expand all | Expand 10 after
1427 data->setPseudoElement(AFTER, 0); 1427 data->setPseudoElement(AFTER, 0);
1428 data->setPseudoElement(BACKDROP, 0); 1428 data->setPseudoElement(BACKDROP, 0);
1429 data->clearComputedStyle(); 1429 data->clearComputedStyle();
1430 data->resetDynamicRestyleObservations(); 1430 data->resetDynamicRestyleObservations();
1431 data->setIsInsideRegion(false); 1431 data->setIsInsideRegion(false);
1432 1432
1433 // Only clear the style state if we're not going to reuse the style from recalcStyle. 1433 // Only clear the style state if we're not going to reuse the style from recalcStyle.
1434 if (!context.resolvedStyle) 1434 if (!context.resolvedStyle)
1435 data->resetStyleState(); 1435 data->resetStyleState();
1436 1436
1437 if (RuntimeEnabledFeatures::webAnimationsCSSEnabled() && !context.perfor mingReattach) { 1437 if (RuntimeEnabledFeatures::webAnimationsCSSEnabled()) {
1438 if (ActiveAnimations* activeAnimations = data->activeAnimations()) 1438 if (ActiveAnimations* activeAnimations = data->activeAnimations()) {
1439 activeAnimations->cssAnimations().cancel(); 1439 if (context.performingReattach) {
1440 // FIXME: restart compositor animations rather than pull bac k to the main thread
1441 activeAnimations->cancelCompositorAnimations();
1442 } else {
1443 activeAnimations->cssAnimations().cancel();
1444 }
1445 }
1440 } 1446 }
1441 } 1447 }
1442 if (ElementShadow* shadow = this->shadow()) 1448 if (ElementShadow* shadow = this->shadow())
1443 shadow->detach(context); 1449 shadow->detach(context);
1444 ContainerNode::detach(context); 1450 ContainerNode::detach(context);
1445 } 1451 }
1446 1452
1447 bool Element::pseudoStyleCacheIsInvalid(const RenderStyle* currentStyle, RenderS tyle* newStyle) 1453 bool Element::pseudoStyleCacheIsInvalid(const RenderStyle* currentStyle, RenderS tyle* newStyle)
1448 { 1454 {
1449 ASSERT(currentStyle == renderStyle()); 1455 ASSERT(currentStyle == renderStyle());
(...skipping 2064 matching lines...) Expand 10 before | Expand all | Expand 10 after
3514 // Before doing so, we need to resolve issues in HTMLSelectElement::recalcLi stItems 3520 // Before doing so, we need to resolve issues in HTMLSelectElement::recalcLi stItems
3515 // and RenderMenuList::setText. See also https://bugs.webkit.org/show_bug.cg i?id=88405 3521 // and RenderMenuList::setText. See also https://bugs.webkit.org/show_bug.cg i?id=88405
3516 if (hasTagName(optionTag) || hasTagName(optgroupTag)) 3522 if (hasTagName(optionTag) || hasTagName(optgroupTag))
3517 return false; 3523 return false;
3518 if (FullscreenElementStack::isActiveFullScreenElement(this)) 3524 if (FullscreenElementStack::isActiveFullScreenElement(this))
3519 return false; 3525 return false;
3520 return true; 3526 return true;
3521 } 3527 }
3522 3528
3523 } // namespace WebCore 3529 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698