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

Unified Diff: Source/bindings/core/v8/ScriptDebugServer.cpp

Issue 391963002: [Blink] XMLTreeViewer should load resources from blink_resources.grd instead of relying upon xxd.py (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 5 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
« no previous file with comments | « no previous file | Source/build/ConvertFileToHeaderWithCharacterArray.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/core/v8/ScriptDebugServer.cpp
diff --git a/Source/bindings/core/v8/ScriptDebugServer.cpp b/Source/bindings/core/v8/ScriptDebugServer.cpp
index 964c8a4832652d6b08b95eacbaa68ce2e3837ff7..f899d65951607bc728dd4f2b4d2600e3dc5aa3dd 100644
--- a/Source/bindings/core/v8/ScriptDebugServer.cpp
+++ b/Source/bindings/core/v8/ScriptDebugServer.cpp
@@ -39,10 +39,11 @@
#include "bindings/core/v8/V8Binding.h"
#include "bindings/core/v8/V8JavaScriptCallFrame.h"
#include "bindings/core/v8/V8ScriptRunner.h"
-#include "core/DebuggerScriptSource.h"
#include "core/inspector/JavaScriptCallFrame.h"
#include "core/inspector/ScriptDebugListener.h"
#include "platform/JSONValues.h"
+#include "public/platform/Platform.h"
+#include "public/platform/WebData.h"
#include "wtf/StdLibExtras.h"
#include "wtf/Vector.h"
#include "wtf/dtoa/utils.h"
@@ -556,7 +557,8 @@ void ScriptDebugServer::ensureDebuggerScriptCompiled()
v8::HandleScope scope(m_isolate);
v8::Context::Scope contextScope(v8::Debug::GetDebugContext());
- v8::Handle<v8::String> source = v8String(m_isolate, String(reinterpret_cast<const char*>(DebuggerScriptSource_js), sizeof(DebuggerScriptSource_js)));
+ const blink::WebData& debuggerScriptSourceResource = blink::Platform::current()->loadResource("DebuggerScriptSource.js");
+ v8::Handle<v8::String> source = v8String(m_isolate, String(debuggerScriptSourceResource.data(), debuggerScriptSourceResource.size()));
v8::Local<v8::Value> value = V8ScriptRunner::compileAndRunInternalScript(source, m_isolate);
ASSERT(!value.IsEmpty());
ASSERT(value->IsObject());
« no previous file with comments | « no previous file | Source/build/ConvertFileToHeaderWithCharacterArray.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698