kopia lustrzana https://github.com/backface/turtlestitch
removed some obsolete comments
rodzic
bb8d63ceb6
commit
bffa7e5da7
|
@ -4211,7 +4211,7 @@ SpriteMorph.prototype.setColor = function (aColor) {
|
||||||
var x = this.xPosition(),
|
var x = this.xPosition(),
|
||||||
y = this.yPosition();
|
y = this.yPosition();
|
||||||
if (!this.color.eq(aColor, true)) { // observeAlpha
|
if (!this.color.eq(aColor, true)) { // observeAlpha
|
||||||
this.color = aColor.copy(); // +++ why copy?
|
this.color = aColor.copy();
|
||||||
if (!this.costume) {
|
if (!this.costume) {
|
||||||
this.rerender();
|
this.rerender();
|
||||||
this.silentGotoXY(x, y);
|
this.silentGotoXY(x, y);
|
||||||
|
@ -7681,7 +7681,7 @@ StageMorph.prototype.penTrailsMorph = function () { // +++ review and refactor
|
||||||
return morph;
|
return morph;
|
||||||
};
|
};
|
||||||
|
|
||||||
StageMorph.prototype.projectionLayer = function () { // +++ review and recycle
|
StageMorph.prototype.projectionLayer = function () {
|
||||||
if (!this.projectionCanvas) {
|
if (!this.projectionCanvas) {
|
||||||
this.projectionCanvas = newCanvas(this.dimensions, true);
|
this.projectionCanvas = newCanvas(this.dimensions, true);
|
||||||
}
|
}
|
||||||
|
@ -8992,7 +8992,7 @@ StageMorph.prototype.changeColorComponentHSVA
|
||||||
|
|
||||||
StageMorph.prototype.setColor = function (aColor) {
|
StageMorph.prototype.setColor = function (aColor) {
|
||||||
if (!this.color.eq(aColor, true)) { // observeAlpha
|
if (!this.color.eq(aColor, true)) { // observeAlpha
|
||||||
this.color = aColor.copy(); // +++ why copy?
|
this.color = aColor.copy();
|
||||||
this.rerender();
|
this.rerender();
|
||||||
this.cachedHSV = this.color.hsv();
|
this.cachedHSV = this.color.hsv();
|
||||||
}
|
}
|
||||||
|
@ -10786,8 +10786,6 @@ CellMorph.prototype.createContents = function () {
|
||||||
isSameTable = this.contentsMorph instanceof TableFrameMorph
|
isSameTable = this.contentsMorph instanceof TableFrameMorph
|
||||||
&& (this.contentsMorph.tableMorph.table === this.contents);
|
&& (this.contentsMorph.tableMorph.table === this.contents);
|
||||||
|
|
||||||
// +++ to do: combine both tests into a single exit condition
|
|
||||||
|
|
||||||
if (this.contentsMorph && !isSameList && !isSameTable) {
|
if (this.contentsMorph && !isSameList && !isSameTable) {
|
||||||
this.contentsMorph.destroy();
|
this.contentsMorph.destroy();
|
||||||
this.version = null;
|
this.version = null;
|
||||||
|
|
Ładowanie…
Reference in New Issue