[Pkg-mozext-commits] [firebug] 43/82: Don't display internal things in closures in the DOM panel
David Prévot
taffit at moszumanska.debian.org
Mon Mar 31 22:45:39 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to tag fbtest-1.11.2
in repository firebug.
commit 9d10641e10da459b8e914b12ffca327bab5e27a4
Author: Simon Lindholm <simon.lindholm10 at gmail.com>
Date: Wed Jan 2 00:28:35 2013 +0100
Don't display internal things in closures in the DOM panel
---
extension/content/firebug/chrome/activation.js | 2 ++
extension/content/firebug/chrome/reps.js | 2 +-
extension/content/firebug/console/closureInspector.js | 9 ++++++++-
extension/content/firebug/dom/domPanel.js | 7 +++++--
4 files changed, 16 insertions(+), 4 deletions(-)
diff --git a/extension/content/firebug/chrome/activation.js b/extension/content/firebug/chrome/activation.js
index c1e1f75..3fd256f 100644
--- a/extension/content/firebug/chrome/activation.js
+++ b/extension/content/firebug/chrome/activation.js
@@ -171,8 +171,10 @@ Firebug.Activation = Obj.extend(Firebug.Module,
catch (exc)
{
if (FBTrace.DBG_ERRORS)
+ {
FBTrace.sysout("pageHasAnnotation FAILS for url: " + url + " which gave uri " +
(uri ? uri.spec : "null"), exc);
+ }
}
},
diff --git a/extension/content/firebug/chrome/reps.js b/extension/content/firebug/chrome/reps.js
index cacabb3..24c89af 100644
--- a/extension/content/firebug/chrome/reps.js
+++ b/extension/content/firebug/chrome/reps.js
@@ -3333,7 +3333,7 @@ FirebugReps.ClosureScope = domplate(Firebug.Rep,
getTitle: function(object)
{
- var scope = Object.getPrototypeOf(object).scope;
+ var scope = ClosureInspector.getScopeFromWrapper(object);
var type = scope.type, title;
if (type === "declarative")
title = Locale.$STR("firebug.reps.declarativeScope");
diff --git a/extension/content/firebug/console/closureInspector.js b/extension/content/firebug/console/closureInspector.js
index a8fab11..8e2e7d7 100644
--- a/extension/content/firebug/console/closureInspector.js
+++ b/extension/content/firebug/console/closureInspector.js
@@ -378,7 +378,9 @@ var ClosureInspector =
set: (dval === OptimizedAway ? undefined : function(value) {
dval = dwin.makeDebuggeeValue(value);
scope.setVariable(name, dval);
- })
+ }),
+ enumerable: true,
+ configurable: false
};
},
has: function(name)
@@ -405,6 +407,11 @@ var ClosureInspector =
return obj instanceof ScopeProxy;
},
+ getScopeFromWrapper: function(obj)
+ {
+ return Object.getPrototypeOf(obj).scope;
+ },
+
extendLanguageSyntax: function(expr, win, context)
{
// Temporary FireClosure compatibility.
diff --git a/extension/content/firebug/dom/domPanel.js b/extension/content/firebug/dom/domPanel.js
index 41dffa9..b59d253 100644
--- a/extension/content/firebug/dom/domPanel.js
+++ b/extension/content/firebug/dom/domPanel.js
@@ -456,9 +456,12 @@ Firebug.DOMBasePanel.prototype = Obj.extend(Firebug.Panel,
try
{
+ // Make sure not to touch the prototype chain of the magic scope objects.
+ var ownOnly = Firebug.showOwnProperties || isScope;
+ var enumerableOnly = Firebug.showEnumerableProperties;
+
var contentView = this.getObjectView(object);
- var properties = this.getObjectProperties(contentView,
- Firebug.showEnumerableProperties, Firebug.showOwnProperties);
+ var properties = this.getObjectProperties(contentView, enumerableOnly, ownOnly);
properties = Arr.sortUnique(properties);
var addOwn = function(prop)
--
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