Chromium Code Reviews| Index: third_party/WebKit/Source/devtools/front_end/emulation/DeviceModeView.js |
| diff --git a/third_party/WebKit/Source/devtools/front_end/emulation/DeviceModeView.js b/third_party/WebKit/Source/devtools/front_end/emulation/DeviceModeView.js |
| index 486429cc3f224f0c0076684bcaf36d59ff928061..499b78df5d01927437d0d4e07fc58c3464353fa7 100644 |
| --- a/third_party/WebKit/Source/devtools/front_end/emulation/DeviceModeView.js |
| +++ b/third_party/WebKit/Source/devtools/front_end/emulation/DeviceModeView.js |
| @@ -472,8 +472,8 @@ WebInspector.DeviceModeView.prototype = { |
| visiblePageRect.top, |
| Math.min(pageImage.naturalWidth, screenRect.width), |
| Math.min(pageImage.naturalHeight, screenRect.height)); |
| - var mainFrame = mainTarget.resourceTreeModel.mainFrame; |
| - var fileName = mainFrame ? mainFrame.url.trimURL().removeURLFragment() : ""; |
| + var url = mainTarget && mainTarget.inspectedURL() |
|
dgozman
2016/08/20 01:32:00
style: missing semicolon
eostroukhov-old
2016/08/22 17:55:41
Done.
|
| + var fileName = url ? url.trimURL().removeURLFragment() : ""; |
| if (this._model.type() === WebInspector.DeviceModeModel.Type.Device) |
| fileName += WebInspector.UIString("(%s)", this._model.device().title); |
| // Trigger download. |