Skip to content

Commit 72127be

Browse files
committed
Clean up.
1 parent 4e2d3ab commit 72127be

File tree

9 files changed

+17
-18
lines changed

9 files changed

+17
-18
lines changed

examples/jsm/lines/LineGeometry.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ class LineGeometry extends LineSegmentsGeometry {
77

88
super();
99

10+
Object.defineProperty( this, 'isLineGeometry', { value: true } );
11+
1012
this.type = 'LineGeometry';
1113

1214
}
@@ -91,6 +93,4 @@ class LineGeometry extends LineSegmentsGeometry {
9193

9294
}
9395

94-
LineGeometry.prototype.isLineGeometry = true;
95-
9696
export { LineGeometry };

examples/jsm/lines/LineSegmentsGeometry.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ class LineSegmentsGeometry extends InstancedBufferGeometry {
1818

1919
super();
2020

21+
Object.defineProperty( this, 'isLineSegmentsGeometry', { value: true } );
22+
2123
this.type = 'LineSegmentsGeometry';
2224

2325
var positions = [ - 1, 2, 0, 1, 2, 0, - 1, 1, 0, 1, 1, 0, - 1, 0, 0, 1, 0, 0, - 1, - 1, 0, 1, - 1, 0 ];
@@ -244,6 +246,4 @@ class LineSegmentsGeometry extends InstancedBufferGeometry {
244246

245247
}
246248

247-
LineSegmentsGeometry.prototype.isLineSegmentsGeometry = true;
248-
249249
export { LineSegmentsGeometry };

examples/jsm/lines/WireframeGeometry2.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ class WireframeGeometry2 extends LineSegmentsGeometry {
99

1010
super();
1111

12+
Object.defineProperty( this, 'isWireframeGeometry2', { value: true } );
13+
1214
this.type = 'WireframeGeometry2';
1315

1416
this.fromWireframeGeometry( new WireframeGeometry( geometry ) );
@@ -19,6 +21,4 @@ class WireframeGeometry2 extends LineSegmentsGeometry {
1921

2022
}
2123

22-
WireframeGeometry.prototype.isWireframeGeometry2 = true;
23-
2424
export { WireframeGeometry2 };

src/core/BufferAttribute.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ class BufferAttribute {
1717

1818
}
1919

20+
Object.defineProperty( this, 'isBufferAttribute', { value: true } );
21+
2022
this.name = '';
2123

2224
this.array = array;
@@ -401,8 +403,6 @@ class BufferAttribute {
401403

402404
}
403405

404-
BufferAttribute.prototype.isBufferAttribute = true;
405-
406406
//
407407

408408
class Int8BufferAttribute extends BufferAttribute {

src/core/Geometry.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ class Geometry extends EventDispatcher {
2121

2222
super();
2323

24+
Object.defineProperty( this, 'isGeometry', { value: true } );
2425
Object.defineProperty( this, 'id', { value: _geometryId += 2 } );
2526

2627
this.uuid = MathUtils.generateUUID();
@@ -1376,6 +1377,4 @@ class Geometry extends EventDispatcher {
13761377

13771378
}
13781379

1379-
Geometry.prototype.isGeometry = true;
1380-
13811380
export { Geometry };

src/core/InstancedBufferAttribute.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ class InstancedBufferAttribute extends BufferAttribute {
66

77
super( array, itemSize, normalized );
88

9+
Object.defineProperty( this, 'isInstancedBufferAttribute', { value: true } );
10+
911
if ( typeof ( normalized ) === 'number' ) {
1012

1113
meshPerAttribute = normalized;
@@ -44,6 +46,4 @@ class InstancedBufferAttribute extends BufferAttribute {
4446

4547
}
4648

47-
InstancedBufferAttribute.prototype.isInstancedBufferAttribute = true;
48-
4949
export { InstancedBufferAttribute };

src/core/InstancedBufferGeometry.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ class InstancedBufferGeometry extends BufferGeometry {
66

77
super();
88

9+
Object.defineProperty( this, 'isInstancedBufferGeometry', { value: true } );
10+
911
this.type = 'InstancedBufferGeometry';
1012
this.instanceCount = Infinity;
1113

@@ -41,6 +43,4 @@ class InstancedBufferGeometry extends BufferGeometry {
4143

4244
}
4345

44-
InstancedBufferGeometry.prototype.isInstancedBufferGeometry = true;
45-
4646
export { InstancedBufferGeometry };

src/core/InstancedInterleavedBuffer.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ class InstancedInterleavedBuffer extends InterleavedBuffer {
66

77
super( array, stride );
88

9+
Object.defineProperty( this, 'isInstancedInterleavedBuffer', { value: true } );
10+
911
this.meshPerAttribute = meshPerAttribute || 1;
1012

1113
}
@@ -43,6 +45,4 @@ class InstancedInterleavedBuffer extends InterleavedBuffer {
4345

4446
}
4547

46-
InstancedInterleavedBuffer.prototype.isInstancedInterleavedBuffer = true;
47-
4848
export { InstancedInterleavedBuffer };

src/core/InterleavedBufferAttribute.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ class InterleavedBufferAttribute {
77

88
constructor( interleavedBuffer, itemSize, offset, normalized ) {
99

10+
Object.defineProperty( this, 'isInterleavedBufferAttribute', { value: true } );
11+
1012
this.name = '';
1113

1214
this.data = interleavedBuffer;
@@ -247,6 +249,4 @@ class InterleavedBufferAttribute {
247249

248250
}
249251

250-
InterleavedBufferAttribute.prototype.isInterleavedBufferAttribute = true;
251-
252252
export { InterleavedBufferAttribute };

0 commit comments

Comments
 (0)