diff options
author | Android (Google) Code Review <android-gerrit@google.com> | 2009-08-27 09:59:39 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2009-08-27 09:59:39 -0700 |
commit | 8e008b4b8cd6aff82cb9a9705e13a637285c705d (patch) | |
tree | a15bc03e37999d5551ee079947915667236599a0 /WebCore | |
parent | dba751b66ddae00363359475121081991cce4793 (diff) | |
parent | 52559759e1a4787355bb696c2087b66106a743aa (diff) | |
download | external_webkit-8e008b4b8cd6aff82cb9a9705e13a637285c705d.zip external_webkit-8e008b4b8cd6aff82cb9a9705e13a637285c705d.tar.gz external_webkit-8e008b4b8cd6aff82cb9a9705e13a637285c705d.tar.bz2 |
Merge changes 22903,22905 into eclair
* changes:
Use v8::V8::LowMemoryNotification() instead of the non-really-existibg v8::V8::CollectAllGarbage()
Update V8 to 2725 to pick up Thread Termination and Low Memory Notification APIs
Diffstat (limited to 'WebCore')
-rw-r--r-- | WebCore/bindings/v8/ScriptController.cpp | 9 | ||||
-rw-r--r-- | WebCore/bindings/v8/ScriptController.h | 3 |
2 files changed, 8 insertions, 4 deletions
diff --git a/WebCore/bindings/v8/ScriptController.cpp b/WebCore/bindings/v8/ScriptController.cpp index 86533f4..48c5115 100644 --- a/WebCore/bindings/v8/ScriptController.cpp +++ b/WebCore/bindings/v8/ScriptController.cpp @@ -271,11 +271,12 @@ void ScriptController::collectGarbage() return; v8::Context::Scope scope(v8Context); -#if PLATFORM(ANDROID) - v8::V8::CollectAllGarbage(); -#else m_proxy->evaluate(ScriptSourceCode("if (window.gc) void(gc());"), 0); -#endif +} + +void ScriptController::lowMemoryNotification() +{ + v8::V8::LowMemoryNotification(); } bool ScriptController::haveInterpreter() const diff --git a/WebCore/bindings/v8/ScriptController.h b/WebCore/bindings/v8/ScriptController.h index 47acf35..d614619 100644 --- a/WebCore/bindings/v8/ScriptController.h +++ b/WebCore/bindings/v8/ScriptController.h @@ -92,6 +92,9 @@ namespace WebCore { void collectGarbage(); + // Notify V8 that the system is running low on memory. + void lowMemoryNotification(); + // Creates a property of the global object of a frame. void bindToWindowObject(Frame*, const String& key, NPObject*); |