| Index: third_party/WebKit/Source/devtools/front_end/screencast/ScreencastView.js
|
| diff --git a/third_party/WebKit/Source/devtools/front_end/screencast/ScreencastView.js b/third_party/WebKit/Source/devtools/front_end/screencast/ScreencastView.js
|
| index 91bbe6654f3b216d8769f52dfda3f6f7e0a6d52a..0b289e4a8447ead96852e59b2b26265fabdafd85 100644
|
| --- a/third_party/WebKit/Source/devtools/front_end/screencast/ScreencastView.js
|
| +++ b/third_party/WebKit/Source/devtools/front_end/screencast/ScreencastView.js
|
| @@ -28,7 +28,7 @@
|
| * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
| */
|
| /**
|
| - * @implements {SDK.DOMNodeHighlighter}
|
| + * @implements {SDK.OverlayModel.Highlighter}
|
| * @unrestricted
|
| */
|
| Screencast.ScreencastView = class extends UI.VBox {
|
| @@ -39,6 +39,7 @@ Screencast.ScreencastView = class extends UI.VBox {
|
| super();
|
| this._screenCaptureModel = screenCaptureModel;
|
| this._domModel = screenCaptureModel.target().model(SDK.DOMModel);
|
| + this._overlayModel = screenCaptureModel.target().model(SDK.OverlayModel);
|
| this._resourceTreeModel = screenCaptureModel.target().model(SDK.ResourceTreeModel);
|
| this._networkManager = screenCaptureModel.target().model(SDK.NetworkManager);
|
| this._inputModel = screenCaptureModel.target().model(Screencast.InputModel);
|
| @@ -130,8 +131,8 @@ Screencast.ScreencastView = class extends UI.VBox {
|
| Math.floor(Math.min(maxImageDimension, dimensions.height)), undefined, this._screencastFrame.bind(this),
|
| this._screencastVisibilityChanged.bind(this));
|
| Emulation.MultitargetTouchModel.instance().setCustomTouchEnabled(true);
|
| - if (this._domModel)
|
| - this._domModel.setHighlighter(this);
|
| + if (this._overlayModel)
|
| + this._overlayModel.setHighlighter(this);
|
| }
|
|
|
| _stopCasting() {
|
| @@ -140,8 +141,8 @@ Screencast.ScreencastView = class extends UI.VBox {
|
| this._isCasting = false;
|
| this._screenCaptureModel.stopScreencast();
|
| Emulation.MultitargetTouchModel.instance().setCustomTouchEnabled(false);
|
| - if (this._domModel)
|
| - this._domModel.setHighlighter(null);
|
| + if (this._overlayModel)
|
| + this._overlayModel.setHighlighter(null);
|
| }
|
|
|
| /**
|
| @@ -245,7 +246,7 @@ Screencast.ScreencastView = class extends UI.VBox {
|
| return;
|
| if (event.type === 'mousemove') {
|
| this.highlightDOMNode(node, this._inspectModeConfig);
|
| - this._domModel.nodeHighlightRequested(node.id);
|
| + this._domModel.overlayModel().nodeHighlightRequested(node.id);
|
| } else if (event.type === 'click') {
|
| Common.Revealer.reveal(node);
|
| }
|
| @@ -316,7 +317,7 @@ Screencast.ScreencastView = class extends UI.VBox {
|
| /**
|
| * @override
|
| * @param {?SDK.DOMNode} node
|
| - * @param {?Protocol.DOM.HighlightConfig} config
|
| + * @param {?Protocol.Overlay.HighlightConfig} config
|
| * @param {!Protocol.DOM.BackendNodeId=} backendNodeId
|
| * @param {!Protocol.Runtime.RemoteObjectId=} objectId
|
| */
|
| @@ -569,14 +570,13 @@ Screencast.ScreencastView = class extends UI.VBox {
|
|
|
| /**
|
| * @override
|
| - * @param {!Protocol.DOM.InspectMode} mode
|
| - * @param {!Protocol.DOM.HighlightConfig} config
|
| - * @param {function(?Protocol.Error)=} callback
|
| + * @param {!Protocol.Overlay.InspectMode} mode
|
| + * @param {!Protocol.Overlay.HighlightConfig} config
|
| + * @return {!Promise}
|
| */
|
| - setInspectMode(mode, config, callback) {
|
| + setInspectMode(mode, config) {
|
| this._inspectModeConfig = mode !== Protocol.DOM.InspectMode.None ? config : null;
|
| - if (callback)
|
| - callback(null);
|
| + return Promise.resolve();
|
| }
|
|
|
| /**
|
|
|