summaryrefslogtreecommitdiff
path: root/Source/JavaScriptCore/inspector/InjectedScriptManager.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/JavaScriptCore/inspector/InjectedScriptManager.h')
-rw-r--r--Source/JavaScriptCore/inspector/InjectedScriptManager.h20
1 files changed, 9 insertions, 11 deletions
diff --git a/Source/JavaScriptCore/inspector/InjectedScriptManager.h b/Source/JavaScriptCore/inspector/InjectedScriptManager.h
index bcc64e2a4..8475e42f7 100644
--- a/Source/JavaScriptCore/inspector/InjectedScriptManager.h
+++ b/Source/JavaScriptCore/inspector/InjectedScriptManager.h
@@ -11,7 +11,7 @@
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
- * 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of
+ * 3. Neither the name of Apple Inc. ("Apple") nor the names of
* its contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
@@ -27,8 +27,7 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef InjectedScriptManager_h
-#define InjectedScriptManager_h
+#pragma once
#include "InjectedScript.h"
#include "InjectedScriptHost.h"
@@ -50,36 +49,35 @@ namespace Inspector {
class JS_EXPORT_PRIVATE InjectedScriptManager {
WTF_MAKE_NONCOPYABLE(InjectedScriptManager); WTF_MAKE_FAST_ALLOCATED;
public:
- InjectedScriptManager(InspectorEnvironment&, PassRefPtr<InjectedScriptHost>);
+ InjectedScriptManager(InspectorEnvironment&, Ref<InjectedScriptHost>&&);
virtual ~InjectedScriptManager();
virtual void disconnect();
+ virtual void discardInjectedScripts();
- InjectedScriptHost* injectedScriptHost();
+ InjectedScriptHost& injectedScriptHost();
InspectorEnvironment& inspectorEnvironment() const { return m_environment; }
InjectedScript injectedScriptFor(JSC::ExecState*);
InjectedScript injectedScriptForId(int);
int injectedScriptIdFor(JSC::ExecState*);
InjectedScript injectedScriptForObjectId(const String& objectId);
- void discardInjectedScripts();
void releaseObjectGroup(const String& objectGroup);
+ void clearExceptionValue();
protected:
- virtual void didCreateInjectedScript(InjectedScript);
+ virtual void didCreateInjectedScript(const InjectedScript&);
HashMap<int, InjectedScript> m_idToInjectedScript;
HashMap<JSC::ExecState*, int> m_scriptStateToId;
private:
String injectedScriptSource();
- Deprecated::ScriptObject createInjectedScript(const String& source, JSC::ExecState*, int id);
+ JSC::JSObject* createInjectedScript(const String& source, JSC::ExecState*, int id);
InspectorEnvironment& m_environment;
- RefPtr<InjectedScriptHost> m_injectedScriptHost;
+ Ref<InjectedScriptHost> m_injectedScriptHost;
int m_nextInjectedScriptId;
};
} // namespace Inspector
-
-#endif // !defined(InjectedScriptManager_h)