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

Side by Side Diff: Source/core/workers/WorkerConsole.h

Issue 177073004: Oilpan: move core/workers to oilpan's heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2007 Apple Inc. All rights reserved.
3 * Copyright (C) 2013 Google Inc. All rights reserved. 3 * Copyright (C) 2013 Google 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 16 matching lines...) Expand all
27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 */ 28 */
29 29
30 #ifndef WorkerConsole_h 30 #ifndef WorkerConsole_h
31 #define WorkerConsole_h 31 #define WorkerConsole_h
32 32
33 #include "bindings/v8/ScriptWrappable.h" 33 #include "bindings/v8/ScriptWrappable.h"
34 #include "core/inspector/ConsoleAPITypes.h" 34 #include "core/inspector/ConsoleAPITypes.h"
35 #include "core/frame/ConsoleBase.h" 35 #include "core/frame/ConsoleBase.h"
36 #include "core/frame/ConsoleTypes.h" 36 #include "core/frame/ConsoleTypes.h"
37 #include "heap/Handle.h"
37 #include "wtf/PassRefPtr.h" 38 #include "wtf/PassRefPtr.h"
38 #include "wtf/RefCounted.h" 39 #include "wtf/RefCounted.h"
39 #include "wtf/RefPtr.h" 40 #include "wtf/RefPtr.h"
40 #include "wtf/text/WTFString.h" 41 #include "wtf/text/WTFString.h"
41 42
42 namespace WebCore { 43 namespace WebCore {
43 44
44 class ScriptArguments; 45 class ScriptArguments;
45 46
46 class WorkerConsole FINAL : public RefCounted<WorkerConsole>, public ConsoleBase , public ScriptWrappable { 47 class WorkerConsole FINAL : public RefCountedWillBeRefCountedGarbageCollected<Wo rkerConsole>, public ConsoleBase, public ScriptWrappable {
48 DECLARE_GC_INFO;
47 public: 49 public:
48 using RefCounted<WorkerConsole>::ref; 50 using RefCountedWillBeRefCountedGarbageCollected<WorkerConsole>::ref;
haraken 2014/02/24 13:28:36 Probably can you use: #if ENABLE(OILPAN) using
sof 2014/02/24 22:44:27 If I understand you correctly, not until we can re
49 using RefCounted<WorkerConsole>::deref; 51 using RefCountedWillBeRefCountedGarbageCollected<WorkerConsole>::deref;
50 52
51 static PassRefPtr<WorkerConsole> create(WorkerGlobalScope* scope) { return a doptRef(new WorkerConsole(scope)); } 53 static PassRefPtrWillBeRawPtr<WorkerConsole> create(WorkerGlobalScope* scope )
54 {
55 return adoptRefCountedWillBeRefCountedGarbageCollected(new WorkerConsole (scope));
56 }
52 virtual ~WorkerConsole(); 57 virtual ~WorkerConsole();
53 58
59 void trace(Visitor*) { }
60
54 protected: 61 protected:
55 virtual ExecutionContext* context() OVERRIDE; 62 virtual ExecutionContext* context() OVERRIDE;
56 virtual void reportMessageToClient(MessageLevel, const String& message, Pass RefPtr<ScriptCallStack>) OVERRIDE; 63 virtual void reportMessageToClient(MessageLevel, const String& message, Pass RefPtr<ScriptCallStack>) OVERRIDE;
57 64
58 private: 65 private:
59 explicit WorkerConsole(WorkerGlobalScope*); 66 explicit WorkerConsole(WorkerGlobalScope*);
60 67
61 virtual void refConsole() OVERRIDE { ref(); } 68 virtual void refConsole() OVERRIDE { ref(); }
62 virtual void derefConsole() OVERRIDE { deref(); } 69 virtual void derefConsole() OVERRIDE { deref(); }
63 70
64 WorkerGlobalScope* m_scope; 71 WorkerGlobalScope* m_scope;
haraken 2014/02/24 13:28:36 You need to change this to a Member.
sof 2014/02/24 22:44:27 Done.
65 }; 72 };
66 73
67 } // namespace WebCore 74 } // namespace WebCore
68 75
69 #endif // WorkerConsole_h 76 #endif // WorkerConsole_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698