X-Git-Url: https://git.saurik.com/apple/javascriptcore.git/blobdiff_plain/81345200c95645a1b0d2635520f96ad55dfde63f..40a37d088818fc2fbeba2ef850dbcaaf294befbf:/inspector/JSGlobalObjectInspectorController.cpp diff --git a/inspector/JSGlobalObjectInspectorController.cpp b/inspector/JSGlobalObjectInspectorController.cpp index 4b8301a..ebdd180 100644 --- a/inspector/JSGlobalObjectInspectorController.cpp +++ b/inspector/JSGlobalObjectInspectorController.cpp @@ -48,6 +48,11 @@ #include #include +#if ENABLE(REMOTE_INSPECTOR) +#include "JSGlobalObjectDebuggable.h" +#include "RemoteInspector.h" +#endif + using namespace JSC; namespace Inspector { @@ -175,6 +180,19 @@ ConsoleClient* JSGlobalObjectInspectorController::consoleClient() const return m_consoleClient.get(); } +bool JSGlobalObjectInspectorController::developerExtrasEnabled() const +{ +#if ENABLE(REMOTE_INSPECTOR) + if (!RemoteInspector::shared().enabled()) + return false; + + if (!m_globalObject.inspectorDebuggable().remoteDebuggingAllowed()) + return false; +#endif + + return true; +} + InspectorFunctionCallHandler JSGlobalObjectInspectorController::functionCallHandler() const { return JSC::call;