Bug 1328679 - Uplift a couple bugs. r=ttromey a=jcristau
authorJason Laster <jason.laster.11@gmail.com>
Wed, 04 Jan 2017 12:05:00 -0500
changeset 353573 a8b681d5b4755427b88651496dcc14a7549a1117
parent 353572 3307299b3069e4a3418a9ffeffc8c69e1d6eb0a7
child 353574 43b203270b27e2f36048d10b27275675823df296
push id6795
push userjlund@mozilla.com
push dateMon, 23 Jan 2017 14:19:46 +0000
treeherdermozilla-esr52@76101b503191 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersttromey, jcristau
bugs1328679
milestone52.0a2
Bug 1328679 - Uplift a couple bugs. r=ttromey a=jcristau
devtools/client/debugger/new/bundle.js
devtools/client/debugger/new/source-map-worker.js
--- a/devtools/client/debugger/new/bundle.js
+++ b/devtools/client/debugger/new/bundle.js
@@ -35259,18 +35259,20 @@ var Debugger =
 	  },
 	
 	  render: function () {
 	    var _state = this.state;
 	    var focusedItem = _state.focusedItem;
 	    var sourceTree = _state.sourceTree;
 	    var parentMap = _state.parentMap;
 	
+        const isEmpty = sourceTree.contents.length === 0;
 	
 	    var tree = ManagedTree({
+          key: isEmpty ? "empty" : "full",
 	      getParent: item => {
 	        return parentMap.get(item);
 	      },
 	      getChildren: item => {
 	        if (nodeHasChildren(item)) {
 	          return item.contents;
 	        }
 	        return [];
@@ -37350,18 +37352,20 @@ var Debugger =
 	__webpack_require__(396);
 	
 	var ManagedTree = React.createClass({
 	  propTypes: Tree.propTypes,
 	
 	  displayName: "ManagedTree",
 	
 	  getInitialState() {
-	    return { expanded: new Set(),
-	      focusedItem: null };
+	    return {
+          expanded: new Set(),
+	      focusedItem: null
+        };
 	  },
 	
 	  setExpanded(item, isExpanded) {
 	    var expanded = this.state.expanded;
 	    var key = this.props.getKey(item);
 	    if (isExpanded) {
 	      expanded.add(key);
 	    } else {
@@ -58323,9 +58327,9 @@ var Debugger =
 	module.exports = {
 	  getStr,
 	  getFormatStr,
 	  setBundle
 	};
 
 /***/ }
 /******/ ]);
-//# sourceMappingURL=bundle.js.map
\ No newline at end of file
+//# sourceMappingURL=bundle.js.map
--- a/devtools/client/debugger/new/source-map-worker.js
+++ b/devtools/client/debugger/new/source-map-worker.js
@@ -84,17 +84,18 @@ var Debugger =
 	    var map = yield _getSourceMap(generatedSourceId);
 	    if (!map) {
 	      return location;
 	    }
 	
 	    var _map$generatedPositio = map.generatedPositionFor({
 	      source: originalSource.url,
 	      line: location.line,
-	      column: location.column == null ? 0 : location.column
+	      column: location.column == null ? 0 : location.column,
+          bias: SourceMapConsumer.LEAST_UPPER_BOUND
 	    });
 	
 	    var line = _map$generatedPositio.line;
 	    var column = _map$generatedPositio.column;
 	
 	
 	    return {
 	      sourceId: generatedSourceId,
@@ -5822,9 +5823,9 @@ var Debugger =
 	};
 	
 	exports.SourceNode = SourceNode;
 
 
 /***/ }
 
 /******/ });
-//# sourceMappingURL=source-map-worker.js.map
\ No newline at end of file
+//# sourceMappingURL=source-map-worker.js.map