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

Side by Side Diff: Source/core/dom/custom/CustomElementMicrotaskImportStep.cpp

Issue 296703009: Oilpan: move custom element objects to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix compilation issue pointed out by clang Created 6 years, 7 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 21 matching lines...) Expand all
32 #include "core/dom/custom/CustomElementMicrotaskImportStep.h" 32 #include "core/dom/custom/CustomElementMicrotaskImportStep.h"
33 33
34 #include "core/dom/custom/CustomElementMicrotaskDispatcher.h" 34 #include "core/dom/custom/CustomElementMicrotaskDispatcher.h"
35 #include "core/dom/custom/CustomElementMicrotaskQueue.h" 35 #include "core/dom/custom/CustomElementMicrotaskQueue.h"
36 #include "core/html/imports/HTMLImportChild.h" 36 #include "core/html/imports/HTMLImportChild.h"
37 #include "core/html/imports/HTMLImportLoader.h" 37 #include "core/html/imports/HTMLImportLoader.h"
38 #include <stdio.h> 38 #include <stdio.h>
39 39
40 namespace WebCore { 40 namespace WebCore {
41 41
42 PassOwnPtr<CustomElementMicrotaskImportStep> CustomElementMicrotaskImportStep::c reate(HTMLImportChild* import) 42 PassOwnPtrWillBeRawPtr<CustomElementMicrotaskImportStep> CustomElementMicrotaskI mportStep::create(HTMLImportChild* import)
43 { 43 {
44 return adoptPtr(new CustomElementMicrotaskImportStep(import)); 44 return adoptPtrWillBeNoop(new CustomElementMicrotaskImportStep(import));
45 } 45 }
46 46
47 CustomElementMicrotaskImportStep::CustomElementMicrotaskImportStep(HTMLImportChi ld* import) 47 CustomElementMicrotaskImportStep::CustomElementMicrotaskImportStep(HTMLImportChi ld* import)
48 : m_import(import->weakPtr()) 48 : m_import(import->weakPtr())
49 , m_queue(import->loader()->microtaskQueue()) 49 , m_queue(import->loader()->microtaskQueue())
50 , m_weakFactory(this) 50 , m_weakFactory(this)
51 { 51 {
52 } 52 }
53 53
54 CustomElementMicrotaskImportStep::~CustomElementMicrotaskImportStep() 54 CustomElementMicrotaskImportStep::~CustomElementMicrotaskImportStep()
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 if (!shouldStopProcessing()) 89 if (!shouldStopProcessing())
90 result = Result(result & ~ShouldStop); 90 result = Result(result & ~ShouldStop);
91 return result; 91 return result;
92 } 92 }
93 93
94 bool CustomElementMicrotaskImportStep::needsProcessOrStop() const 94 bool CustomElementMicrotaskImportStep::needsProcessOrStop() const
95 { 95 {
96 return shouldStopProcessing() || m_queue->needsProcessOrStop(); 96 return shouldStopProcessing() || m_queue->needsProcessOrStop();
97 } 97 }
98 98
99 void CustomElementMicrotaskImportStep::trace(Visitor* visitor)
100 {
101 visitor->trace(m_queue);
102 CustomElementMicrotaskStep::trace(visitor);
103 }
104
99 #if !defined(NDEBUG) 105 #if !defined(NDEBUG)
100 void CustomElementMicrotaskImportStep::show(unsigned indent) 106 void CustomElementMicrotaskImportStep::show(unsigned indent)
101 { 107 {
102 fprintf(stderr, "%*sImport(wait=%d sync=%d, url=%s)\n", indent, "", shouldWa itForImport(), shouldStopProcessing(), m_import ? m_import->url().string().utf8( ).data() : "null"); 108 fprintf(stderr, "%*sImport(wait=%d sync=%d, url=%s)\n", indent, "", shouldWa itForImport(), shouldStopProcessing(), m_import ? m_import->url().string().utf8( ).data() : "null");
103 m_queue->show(indent + 1); 109 m_queue->show(indent + 1);
104 } 110 }
105 #endif 111 #endif
106 112
107 } // namespace WebCore 113 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/dom/custom/CustomElementMicrotaskImportStep.h ('k') | Source/core/dom/custom/CustomElementMicrotaskQueue.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698