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

Unified Diff: Source/core/frame/ConsoleBase.h

Issue 206093005: Oilpan: move Console objects to the oilpan heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/frame/ConsoleBase.h
diff --git a/Source/core/frame/ConsoleBase.h b/Source/core/frame/ConsoleBase.h
index 30858d02731c7ea1f4b7b848787a6a7801eec62b..0755b5ccc010e896b2e8ce37e3d4b6e94cfc7a27 100644
--- a/Source/core/frame/ConsoleBase.h
+++ b/Source/core/frame/ConsoleBase.h
@@ -36,6 +36,7 @@
#include "core/inspector/ScriptCallStack.h"
#include "core/frame/ConsoleTypes.h"
#include "core/frame/DOMWindowProperty.h"
+#include "heap/Handle.h"
#include "wtf/Forward.h"
#include "wtf/PassRefPtr.h"
#include "wtf/RefCounted.h"
@@ -44,10 +45,12 @@ namespace WebCore {
class ScriptArguments;
-class ConsoleBase {
+class ConsoleBase : public NoBaseWillBeGarbageCollectedFinalized<ConsoleBase> {
public:
+#if !ENABLE(OILPAN)
void ref() { refConsole(); }
Mads Ager (chromium) 2014/03/20 14:20:01 WAT!?! What is this, I don't even?!? Why isn't Co
sof 2014/03/20 14:57:23 Not missing anything, it definitely can be simplif
void deref() { derefConsole(); }
+#endif
void debug(ScriptState*, PassRefPtr<ScriptArguments>);
void error(ScriptState*, PassRefPtr<ScriptArguments>);
@@ -73,14 +76,22 @@ public:
void groupCollapsed(ScriptState*, PassRefPtr<ScriptArguments>);
void groupEnd();
+ virtual void trace(Visitor*) { }
+
+#if !ENABLE(OILPAN)
protected:
+#endif
haraken 2014/03/20 14:13:06 I'd just remove protected: and make the destructor
sof 2014/03/20 14:57:23 yes; with RefCounted<> now on ConsoleBase the slig
virtual ~ConsoleBase();
+
+protected:
virtual ExecutionContext* context() = 0;
virtual void reportMessageToClient(MessageLevel, const String& message, PassRefPtr<ScriptCallStack>) = 0;
private:
+#if !ENABLE(OILPAN)
virtual void refConsole() = 0;
virtual void derefConsole() = 0;
+#endif
void internalAddMessage(MessageType, MessageLevel, ScriptState*, PassRefPtr<ScriptArguments>, bool acceptNoArguments = false, bool printTrace = false);
};

Powered by Google App Engine
This is Rietveld 408576698