Title: [213738] trunk/Source/WebInspectorUI
Revision
213738
Author
commit-qu...@webkit.org
Date
2017-03-10 16:59:24 -0800 (Fri, 10 Mar 2017)

Log Message

Web Inspector: in Resources tab navigation bar, can't save the same file from context menu item more than once
https://bugs.webkit.org/show_bug.cgi?id=165665

Patch by Devin Rousso <dcrousso+web...@gmail.com> on 2017-03-10
Reviewed by Brian Burg.

* UserInterface/Views/ContextMenuUtilities.js:
(WebInspector.appendContextMenuItemsForSourceCode):
Force the "Save As" dialog to appear when saving, as otherwise subsequent clicks on "Save"
in the context menu will just override the previously saved file.

Modified Paths

Diff

Modified: trunk/Source/WebInspectorUI/ChangeLog (213737 => 213738)


--- trunk/Source/WebInspectorUI/ChangeLog	2017-03-11 00:58:42 UTC (rev 213737)
+++ trunk/Source/WebInspectorUI/ChangeLog	2017-03-11 00:59:24 UTC (rev 213738)
@@ -1,5 +1,17 @@
 2017-03-10  Devin Rousso  <dcrousso+web...@gmail.com>
 
+        Web Inspector: in Resources tab navigation bar, can't save the same file from context menu item more than once
+        https://bugs.webkit.org/show_bug.cgi?id=165665
+
+        Reviewed by Brian Burg.
+
+        * UserInterface/Views/ContextMenuUtilities.js:
+        (WebInspector.appendContextMenuItemsForSourceCode):
+        Force the "Save As" dialog to appear when saving, as otherwise subsequent clicks on "Save"
+        in the context menu will just override the previously saved file.
+
+2017-03-10  Devin Rousso  <dcrousso+web...@gmail.com>
+
         Web Inspector: REGRESSION(r213149): scope bar items in elements sidebar have wrong padding/margin
         https://bugs.webkit.org/show_bug.cgi?id=169204
 

Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js (213737 => 213738)


--- trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js	2017-03-11 00:58:42 UTC (rev 213737)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js	2017-03-11 00:59:24 UTC (rev 213738)
@@ -73,10 +73,11 @@
 
     contextMenu.appendItem(WebInspector.UIString("Save File"), () => {
         sourceCode.requestContent().then(() => {
+            const forceSaveAs = true;
             WebInspector.saveDataToFile({
                 url: sourceCode.url || "",
                 content: sourceCode.content
-            });
+            }, forceSaveAs);
         });
     });
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to