[Pkg-mozext-commits] [firebug] 45/59: Some cleanups in debugger/script/sourceTool.js
David Prévot
taffit at moszumanska.debian.org
Thu Aug 14 14:52:56 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository firebug.
commit 017705589d8c0bff273b721d9efc453a207081ea
Author: Florent FAYOLLE <florent.fayolle69 at gmail.com>
Date: Sat Aug 9 14:08:38 2014 +0200
Some cleanups in debugger/script/sourceTool.js
---
.../content/firebug/debugger/script/sourceTool.js | 20 +++++++++-----------
1 file changed, 9 insertions(+), 11 deletions(-)
diff --git a/extension/content/firebug/debugger/script/sourceTool.js b/extension/content/firebug/debugger/script/sourceTool.js
index 69c4624..9edefb4 100644
--- a/extension/content/firebug/debugger/script/sourceTool.js
+++ b/extension/content/firebug/debugger/script/sourceTool.js
@@ -213,7 +213,6 @@ SourceTool.prototype = Obj.extend(new Tool(),
if (!sourceFile || !sourceFile.dynamic)
return;
- var sourceFile = this.context.getSourceFile(bp.href);
var scripts = sourceFile.scripts;
if (!scripts.length)
{
@@ -229,8 +228,8 @@ SourceTool.prototype = Obj.extend(new Tool(),
{
var childScripts = parentScript.getChildScripts();
- var scripts = [parentScript];
- scripts.push.apply(scripts, childScripts);
+ scripts = [parentScript];
+ [].push.apply(scripts, childScripts);
for (var script of scripts)
{
@@ -262,7 +261,6 @@ SourceTool.prototype = Obj.extend(new Tool(),
return;
}
- var sourceFile = this.context.getSourceFile(bp.href);
var scripts = sourceFile.scripts;
if (!scripts.length)
{
@@ -274,8 +272,8 @@ SourceTool.prototype = Obj.extend(new Tool(),
{
var childScripts = parentScript.getChildScripts();
- var scripts = [parentScript];
- scripts.push.apply(scripts, childScripts);
+ scripts = [parentScript];
+ [].push.apply(scripts, childScripts);
for (var script of scripts)
{
@@ -436,7 +434,7 @@ DynamicSourceCollector.prototype =
if (!sourceFile)
{
// xxxHonza: there should be only one place where instance of SourceFile is created.
- var sourceFile = new SourceFile(this.context, null, url, false, false);
+ sourceFile = new SourceFile(this.context, null, url, false, false);
// xxxHonza: duplicated from {@link SourceFile}
var source = script.source.text.replace(/\r\n/gm, "\n");
@@ -547,7 +545,7 @@ BreakpointHitHandler.prototype =
var threadActor = DebuggerLib.getThreadActor(this.context.browser);
- var {url} = threadActor.synchronize(
+ threadActor.synchronize(
threadActor.sources.getOriginalLocation({
url: this.bp.href,
line: this.bp.lineNo,
@@ -568,7 +566,7 @@ BreakpointHitHandler.prototype =
// The debugging will start as usual within {@link DebuggerTool#paused} method.
return threadActor._pauseAndRespond(frame, {type: "dynamic-breakpoint"});
}
-}
+};
// ********************************************************************************************* //
// StackFrame Patch
@@ -657,7 +655,7 @@ ErrorStackTraceObserver.getSourceFile = function(context, script)
return getSourceFileByScript(context, script);
return originalGetSourceFile.apply(ErrorStackTraceObserver, arguments);
-}
+};
// ********************************************************************************************* //
// SourceFile Patch
@@ -731,7 +729,7 @@ function computeDynamicUrl(script, context)
// xxxHonza: hide this, scriptElement scripts don't have introductionScript.
//TraceError.sysout("sourceTool.computeDynamicUrl; ERROR No introductionScript: " +
// script.source.url);
- return Url.normalizeURL(script.source.url + "/" + displayURL);displayURL;
+ return Url.normalizeURL(script.source.url + "/" + displayURL);
}
return Url.normalizeURL(introScript.url + "/" + displayURL);
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/firebug.git
More information about the Pkg-mozext-commits
mailing list