| Index: Source/devtools/front_end/sdk/RuntimeModel.js
|
| diff --git a/Source/devtools/front_end/sdk/RuntimeModel.js b/Source/devtools/front_end/sdk/RuntimeModel.js
|
| index d5bad7396aea8b3de55a72428f5ec9e37576a8e6..ffd6b0ad01b0aad56b48df7d326ddc3f982c6521 100644
|
| --- a/Source/devtools/front_end/sdk/RuntimeModel.js
|
| +++ b/Source/devtools/front_end/sdk/RuntimeModel.js
|
| @@ -488,3 +488,64 @@ WebInspector.ExecutionContext.prototype = {
|
|
|
| __proto__: WebInspector.SDKObject.prototype
|
| }
|
| +
|
| +/**
|
| + * @constructor
|
| + * @extends {WebInspector.SDKObject}
|
| + * @param {!WebInspector.Target} target
|
| + * @param {!RuntimeAgent.EventListener} payload
|
| + * @param {string} description
|
| + */
|
| +WebInspector.RuntimeModel.EventListener = function(target, payload, description)
|
| +{
|
| + WebInspector.SDKObject.call(this, target);
|
| + this._payload = payload;
|
| + var script = target.debuggerModel.scriptForId(payload.location.scriptId);
|
| + var sourceName = script ? script.contentURL() : "";
|
| + this._sourceName = sourceName;
|
| + this._description = description;
|
| +}
|
| +
|
| +WebInspector.RuntimeModel.EventListener.prototype = {
|
| + /**
|
| + * @return {!RuntimeAgent.EventListener}
|
| + */
|
| + payload: function()
|
| + {
|
| + return this._payload;
|
| + },
|
| +
|
| + /**
|
| + * @return {!WebInspector.DebuggerModel.Location}
|
| + */
|
| + location: function()
|
| + {
|
| + return WebInspector.DebuggerModel.Location.fromPayload(this.target(), this._payload.location);
|
| + },
|
| +
|
| + /**
|
| + * @return {?WebInspector.RemoteObject}
|
| + */
|
| + handler: function()
|
| + {
|
| + return this._payload.handler ? this.target().runtimeModel.createRemoteObject(this._payload.handler) : null;
|
| + },
|
| +
|
| + /**
|
| + * @return {string}
|
| + */
|
| + sourceName: function()
|
| + {
|
| + return this._sourceName;
|
| + },
|
| +
|
| + /**
|
| + * @return {string}
|
| + */
|
| + description: function()
|
| + {
|
| + return this._description;
|
| + },
|
| +
|
| + __proto__: WebInspector.SDKObject.prototype
|
| +}
|
|
|