Skip to content

Instantly share code, notes, and snippets.

View vivekgalatage's full-sized avatar
👋
Hey!

Vivek Galatage vivekgalatage

👋
Hey!
View GitHub Profile
InjectedScript injectedScript = injectedScriptForEval(errorString, executionContextId);
if (injectedScript.hasNoValue()) {
result = TypeBuilder::Runtime::RemoteObject::create().setType(TypeBuilder::Runtime::RemoteObject::Type::Object);
return;
}
@vivekgalatage
vivekgalatage / gist:4752724
Last active December 12, 2015 09:38
Notifying inspector front-end when the script execution state has been changed (due to browser wide "JavaScript" disable option).
diff --git a/Source/WebCore/inspector/Inspector.json b/Source/WebCore/inspector/Inspector.json
index 1414f64..b9575fb 100644
--- a/Source/WebCore/inspector/Inspector.json
+++ b/Source/WebCore/inspector/Inspector.json
@@ -559,6 +559,14 @@
"name": "javascriptDialogClosed",
"description": "Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) has been closed.",
"hidden": true
+ },
+ {
protocol-test.js
----------------
function runTest():
var url = scriptUrlBasePath + "/protocol-test.html";
var script = "(" + initialize_InspectorTest.toString() + ")();\n" + test.toString() + "";
var inspectorFrontend = window.internals.openDummyInspectorFrontend(url);
inspectorFrontend.postMessage(script, window.location.href);
protocol-test.html
<html>
<head>
<script type="text/javascript" src="../../../../Source/WebCore/inspector/front-end/InspectorBackend.js"></script>
</head>
<body onLoad="InspectorBackend.loadFromJSONIfNeeded(); test();">
</body>
</html>
I: Install complete: 11 files copied
*** Checking out glib *** [8/19]
*** Configuring glib *** [8/19]
./autogen.sh --prefix /home/uma/workspace-android/WebKit/WebKitBuild/Dependencies/Root --libdir '/home/uma/workspace-android/WebKit/WebKitBuild/Dependencies/Root/lib64' --disable-dtrace --disable-static --disable-gtk-doc
*** No GTK-Doc found, please install it ***
*** Error during phase configure of glib: ########## Error running ./autogen.sh --prefix /home/uma/workspace-android/WebKit/WebKitBuild/Dependencies/Root --libdir '/home/uma/workspace-android/WebKit/WebKitBuild/Dependencies/Root/lib64' --disable-dtrace --disable-static --disable-gtk-doc *** [8/19]
*** module gdk-pixbuf not built due to non buildable glib *** [9/19]
*** module pango not built due to non buildable glib *** [10/19]
*** module gtk+ not built due to non buildable glib *** [11/19]
*** module gtk+ not built due to non buildable pango *** [11/19]
harness.js
==========
var initialize_InspectorTest = function() {
counter = 0;
InspectorTest.sendCommand = function(method, params, callback)
{
var parameters = [];
for (var name in params)
parameters.push("\"" + name + "\":" + "\"" + params[name] +"\"");