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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp

Issue 1637083004: CC Animation: Remove meaningless method from WebLayer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « cc/layers/layer.cc ('k') | third_party/WebKit/public/platform/WebLayer.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) 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 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 1101 matching lines...) Expand 10 before | Expand all | Expand 10 after
1112 } 1112 }
1113 1113
1114 setContentsTo(m_imageLayer ? m_imageLayer->layer() : 0); 1114 setContentsTo(m_imageLayer ? m_imageLayer->layer() : 0);
1115 } 1115 }
1116 1116
1117 bool GraphicsLayer::addAnimation(PassOwnPtr<WebCompositorAnimation> popAnimation ) 1117 bool GraphicsLayer::addAnimation(PassOwnPtr<WebCompositorAnimation> popAnimation )
1118 { 1118 {
1119 OwnPtr<WebCompositorAnimation> animation(std::move(popAnimation)); 1119 OwnPtr<WebCompositorAnimation> animation(std::move(popAnimation));
1120 ASSERT(animation); 1120 ASSERT(animation);
1121 platformLayer()->setAnimationDelegate(this); 1121 platformLayer()->setAnimationDelegate(this);
1122
1123 // Remove any existing animations with the same animation id and target prop erty.
1124 platformLayer()->removeAnimation(animation->id(), animation->targetProperty( ));
1125 return platformLayer()->addAnimation(animation.leakPtr()); 1122 return platformLayer()->addAnimation(animation.leakPtr());
1126 } 1123 }
1127 1124
1128 void GraphicsLayer::pauseAnimation(int animationId, double timeOffset) 1125 void GraphicsLayer::pauseAnimation(int animationId, double timeOffset)
1129 { 1126 {
1130 platformLayer()->pauseAnimation(animationId, timeOffset); 1127 platformLayer()->pauseAnimation(animationId, timeOffset);
1131 } 1128 }
1132 1129
1133 void GraphicsLayer::removeAnimation(int animationId) 1130 void GraphicsLayer::removeAnimation(int animationId)
1134 { 1131 {
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
1267 { 1264 {
1268 if (!layer) { 1265 if (!layer) {
1269 fprintf(stderr, "Cannot showGraphicsLayerTree for (nil).\n"); 1266 fprintf(stderr, "Cannot showGraphicsLayerTree for (nil).\n");
1270 return; 1267 return;
1271 } 1268 }
1272 1269
1273 String output = layer->layerTreeAsText(blink::LayerTreeIncludesDebugInfo); 1270 String output = layer->layerTreeAsText(blink::LayerTreeIncludesDebugInfo);
1274 fprintf(stderr, "%s\n", output.utf8().data()); 1271 fprintf(stderr, "%s\n", output.utf8().data());
1275 } 1272 }
1276 #endif 1273 #endif
OLDNEW
« no previous file with comments | « cc/layers/layer.cc ('k') | third_party/WebKit/public/platform/WebLayer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698