| Index: WebCore/inspector/front-end/ScriptsPanel.js
|
| ===================================================================
|
| --- WebCore/inspector/front-end/ScriptsPanel.js (revision 73033)
|
| +++ WebCore/inspector/front-end/ScriptsPanel.js (working copy)
|
| @@ -306,7 +306,7 @@
|
| return Preferences.canEditScriptSource;
|
| },
|
|
|
| - editScriptSource: function(sourceID, newContent, line, linesCountToShift, commitEditingCallback, cancelEditingCallback)
|
| + editScriptSource: function(editData, commitEditingCallback, cancelEditingCallback)
|
| {
|
| if (!this.canEditScripts())
|
| return;
|
| @@ -323,18 +323,19 @@
|
| if (callFrames && callFrames.length)
|
| this.debuggerPaused(callFrames);
|
| } else {
|
| - cancelEditingCallback();
|
| + if (cancelEditingCallback)
|
| + cancelEditingCallback();
|
| WebInspector.log(newBodyOrErrorMessage, WebInspector.ConsoleMessage.MessageLevel.Warning);
|
| }
|
| for (var i = 0; i < breakpoints.length; ++i) {
|
| var breakpoint = breakpoints[i];
|
| var newLine = breakpoint.line;
|
| - if (success && breakpoint.line >= line)
|
| - newLine += linesCountToShift;
|
| - WebInspector.breakpointManager.setBreakpoint(sourceID, breakpoint.url, newLine, breakpoint.enabled, breakpoint.condition);
|
| + if (success && breakpoint.line >= editData.line)
|
| + newLine += editData.linesCountToShift;
|
| + WebInspector.breakpointManager.setBreakpoint(editData.sourceID, breakpoint.url, newLine, breakpoint.enabled, breakpoint.condition);
|
| }
|
| };
|
| - InspectorBackend.editScriptSource(sourceID, newContent, mycallback.bind(this));
|
| + InspectorBackend.editScriptSource(editData.sourceID, editData.content, mycallback.bind(this));
|
| },
|
|
|
| selectedCallFrameId: function()
|
|
|