Skip to content

Commit 8d4a904

Browse files
committed
add palette function
1 parent 4e32e3f commit 8d4a904

File tree

1 file changed

+5
-20
lines changed

1 file changed

+5
-20
lines changed

js/module/tracer/tracer.js

Lines changed: 5 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -50,26 +50,6 @@ class Tracer {
5050
return this;
5151
}
5252

53-
_setSelectedColor(c) {
54-
this.color.selected = c;
55-
}
56-
57-
_setNotifiedColor(c) {
58-
this.color.notified = c;
59-
}
60-
61-
_setVisitedColor(c) {
62-
this.color.visited = c;
63-
}
64-
65-
_setLeftColor(c) {
66-
this.color.left = c;
67-
}
68-
69-
_setDefaultColor(c) {
70-
this.color.default = c;
71-
}
72-
7353
processStep(step, options) {
7454
const {
7555
type,
@@ -127,6 +107,11 @@ class Tracer {
127107
return this;
128108
}
129109

110+
palette(color) {
111+
$.extend(this.color, color);
112+
return this;
113+
}
114+
130115
mousedown(e) {
131116
}
132117

0 commit comments

Comments
 (0)