Skip to content

Commit 58903ac

Browse files
committed
remove some comments
1 parent ab748fe commit 58903ac

6 files changed

Lines changed: 3 additions & 47 deletions

File tree

src/js/viz/interactor/annotation.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
export class Annotation {
22
constructor(annotationName, seqDatum) {
3-
// console.log("**", annotationName, seqDatum);
43
this.description = annotationName.trim();
54
this.seqDatum = seqDatum;
65
}

src/js/viz/interactor/complex.js

Lines changed: 2 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,6 @@ export class Complex extends Interactor {
1313
this.upperGroup = document.createElementNS(svgns, "g");
1414
this.initLabel();
1515
this.padding = 28;
16-
17-
// const self = this;
18-
// // its bad if you end up with these getting called
19-
// Object.defineProperty(this, "width", {
20-
// get: function height() {
21-
// return self.naryLink.path.getBBox().width;
22-
// //return 160;
23-
// }
24-
// });
25-
// Object.defineProperty(this, "height", {
26-
// get: function height() {
27-
// return self.naryLink.path.getBBox().height;
28-
// //return 160;
29-
// }
30-
// });
3116
}
3217

3318
initLink(naryLink) {
@@ -36,15 +21,14 @@ export class Complex extends Interactor {
3621
}
3722

3823
setLinked() {
39-
4024
this.naryLink.path2.classList.add("linked-complex");
4125
}
4226

4327
getPosition(originPoint) {
44-
let mapped = this.naryLink.mapped;//getMappedCoordinates();
28+
let mapped = this.naryLink.mapped;
4529
if (!mapped) {
4630
this.naryLink.setLinkCoordinates();
47-
mapped = this.naryLink.mapped;//this.naryLink.orbitNodeCount(this.naryLink.getMappedCoordinates());
31+
mapped = this.naryLink.mapped;
4832
}
4933
const mc = mapped.length;
5034
let xSum = 0,
@@ -55,8 +39,6 @@ export class Complex extends Interactor {
5539
}
5640
let center = [xSum / mc, ySum / mc];
5741
if (originPoint) {
58-
// if (participant.type === "complex"){
59-
// startPoint = participant.getPosition();
6042
let naryPath = this.naryLink.hull;
6143
let iPath = [];
6244
for (let p of naryPath) {

src/js/viz/interactor/polymer.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,6 @@ import {easeCubicInOut} from "d3-ease";
44
import {rotatePointAboutPoint} from "../../geom";
55
import {svgns} from "../../svgns";
66
import {Interactor} from "./interactor";
7-
// import {Annotation} from "./annotation";
8-
// import {SequenceDatum} from "../sequence-datum";
97

108
export class Polymer extends Interactor {
119
constructor() {

src/js/viz/link/nary-link.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
// import * as d3 from "d3"; //used for d3.geom.hull
21
import {polygonHull} from "d3-polygon";
32
import {Link} from "./link";
43
import {rotatePointAboutPoint} from "../../geom";
@@ -13,23 +12,6 @@ export class NaryLink extends Link {
1312
this.unaryLinks = new Map();
1413
}
1514

16-
/*
17-
NaryLink.prototype.getTotalParticipantCount = function () {
18-
let result = 0;
19-
const c = this.participants.length;
20-
for (let p = 0; p < c; p++) {
21-
const participant = this.participants[p];
22-
//console.log("! " + typeof participant);
23-
if (participant.type !== "complex") {
24-
result++;
25-
} else {
26-
result += participant.naryLink.getTotalParticipantCount();
27-
}
28-
}
29-
return result;
30-
};
31-
*/
32-
3315
get path () {
3416
if (!this._path) {
3517
this._path = this._createElement("path");
@@ -65,7 +47,7 @@ export class NaryLink extends Link {
6547

6648
show() {
6749
// this.path.setAttribute("stroke-width", this.app.z);
68-
// this.setLinkCoordinates(); // todo - having this here slows down start up. instead see lines 41-44 complex.js
50+
// this.setLinkCoordinates(); // having this here slows down start up. instead see getPosition in complex.js
6951
this.app.naryLinks.appendChild(this.path);
7052
this.app.naryLinks.appendChild(this.path2);
7153
}

src/js/viz/link/unary-link.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
//todo - is this even working? you never see it
2-
31
import {HideableLink} from "./hideable-link";
42

53
export class UnaryLink extends HideableLink {

src/js/viz/sequence-datum.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ export class SequenceDatum {
2222
}
2323

2424
if (this.sequenceDatumString === "?-?") {
25-
//this.begin = 1;
2625
this.end = 1; //todo - having it at begining is affecting shape of line, look at why
2726
this.uncertainEnd = participant.size ? participant.size : 1;
2827
} else if (this.sequenceDatumString === "n-n") {
@@ -63,14 +62,12 @@ export class SequenceDatum {
6362
if (this.begin === "n") {
6463
this.uncertainBegin = 1;
6564
this.begin = tidyPosition(this.end);
66-
// this.uncertainEnd = this.end;
6765
this.end = null;
6866
}
6967

7068
if (this.end === "c") {
7169
this.uncertainEnd = participant.size;
7270
this.end = tidyPosition(this.begin);
73-
// this.uncertainBegin = this.begin;
7471
this.begin = null;
7572
}
7673

0 commit comments

Comments
 (0)