Bug 974159 - debugger-controller.js should use ES6 iterators instead of old style iterators; r=past

This commit is contained in:
Nick Fitzgerald 2014-02-26 19:57:46 -08:00
Родитель 08cc73b43d
Коммит d9a3ebe351
1 изменённых файлов: 16 добавлений и 10 удалений

Просмотреть файл

@ -2128,16 +2128,6 @@ Breakpoints.prototype = {
}
},
/**
* Gets all Promises for the BreakpointActor client objects that are
* either enabled (added to the server) or disabled (removed from the server,
* but for which some details are preserved).
*/
get _addedOrDisabled() {
for (let [, value] of this._added) yield value;
for (let [, value] of this._disabled) yield value;
},
/**
* Get a Promise for the BreakpointActor client object which is already added
* or currently being added at the given location.
@ -2180,6 +2170,22 @@ Breakpoints.prototype = {
}
};
/**
* Gets all Promises for the BreakpointActor client objects that are
* either enabled (added to the server) or disabled (removed from the server,
* but for which some details are preserved).
*/
Object.defineProperty(Breakpoints.prototype, "_addedOrDisabled", {
get: function* () {
for (let [, value] of this._added) {
yield value;
}
for (let [, value] of this._disabled) {
yield value;
}
}
});
/**
* Localization convenience methods.
*/