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

Side by Side Diff: third_party/WebKit/Source/core/animation/Animation.cpp

Issue 2080623002: Revert "Remove OwnPtr from Blink." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 27 matching lines...) Expand all
38 #include "core/events/AnimationPlayerEvent.h" 38 #include "core/events/AnimationPlayerEvent.h"
39 #include "core/frame/UseCounter.h" 39 #include "core/frame/UseCounter.h"
40 #include "core/inspector/InspectorInstrumentation.h" 40 #include "core/inspector/InspectorInstrumentation.h"
41 #include "core/inspector/InspectorTraceEvents.h" 41 #include "core/inspector/InspectorTraceEvents.h"
42 #include "platform/RuntimeEnabledFeatures.h" 42 #include "platform/RuntimeEnabledFeatures.h"
43 #include "platform/TraceEvent.h" 43 #include "platform/TraceEvent.h"
44 #include "platform/animation/CompositorAnimationPlayer.h" 44 #include "platform/animation/CompositorAnimationPlayer.h"
45 #include "public/platform/Platform.h" 45 #include "public/platform/Platform.h"
46 #include "public/platform/WebCompositorSupport.h" 46 #include "public/platform/WebCompositorSupport.h"
47 #include "wtf/MathExtras.h" 47 #include "wtf/MathExtras.h"
48 #include "wtf/PtrUtil.h"
49 48
50 namespace blink { 49 namespace blink {
51 50
52 namespace { 51 namespace {
53 52
54 static unsigned nextSequenceNumber() 53 static unsigned nextSequenceNumber()
55 { 54 {
56 static unsigned next = 0; 55 static unsigned next = 0;
57 return ++next; 56 return ++next;
58 } 57 }
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
287 m_currentTimePending = false; 286 m_currentTimePending = false;
288 } 287 }
289 288
290 if (shouldStart) { 289 if (shouldStart) {
291 m_compositorGroup = compositorGroup; 290 m_compositorGroup = compositorGroup;
292 if (startOnCompositor) { 291 if (startOnCompositor) {
293 if (isCandidateForAnimationOnCompositor()) 292 if (isCandidateForAnimationOnCompositor())
294 createCompositorPlayer(); 293 createCompositorPlayer();
295 294
296 if (maybeStartAnimationOnCompositor()) 295 if (maybeStartAnimationOnCompositor())
297 m_compositorState = wrapUnique(new CompositorState(*this)); 296 m_compositorState = adoptPtr(new CompositorState(*this));
298 else 297 else
299 cancelIncompatibleAnimationsOnCompositor(); 298 cancelIncompatibleAnimationsOnCompositor();
300 } 299 }
301 } 300 }
302 301
303 return true; 302 return true;
304 } 303 }
305 304
306 void Animation::postCommit(double timelineTime) 305 void Animation::postCommit(double timelineTime)
307 { 306 {
(...skipping 777 matching lines...) Expand 10 before | Expand all | Expand 10 after
1085 visitor->trace(m_timeline); 1084 visitor->trace(m_timeline);
1086 visitor->trace(m_pendingFinishedEvent); 1085 visitor->trace(m_pendingFinishedEvent);
1087 visitor->trace(m_pendingCancelledEvent); 1086 visitor->trace(m_pendingCancelledEvent);
1088 visitor->trace(m_finishedPromise); 1087 visitor->trace(m_finishedPromise);
1089 visitor->trace(m_readyPromise); 1088 visitor->trace(m_readyPromise);
1090 EventTargetWithInlineData::trace(visitor); 1089 EventTargetWithInlineData::trace(visitor);
1091 ActiveDOMObject::trace(visitor); 1090 ActiveDOMObject::trace(visitor);
1092 } 1091 }
1093 1092
1094 } // namespace blink 1093 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/animation/Animation.h ('k') | third_party/WebKit/Source/core/animation/AnimationClock.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698