summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authortimb <opuscule@gmail.com>2016-03-13 17:46:43 -0700
committertimb <opuscule@gmail.com>2016-03-13 17:46:43 -0700
commitb55c277f18a56cb6c6f85df968111f230e828b07 (patch)
treef2c72f1b1a73251f9ff5a0f37eb59dda68a37546 /js
parentc76582f92f4686dff929bff706b24eb5d1058e78 (diff)
rm lex.fill since it is exactly the same fn as lex.assign
Diffstat (limited to 'js')
-rw-r--r--js/lex.js7
-rw-r--r--js/matrix.js2
-rw-r--r--js/ui/brush.js4
3 files changed, 3 insertions, 10 deletions
diff --git a/js/lex.js b/js/lex.js
index 70dd2bf..b0d6007 100644
--- a/js/lex.js
+++ b/js/lex.js
@@ -84,13 +84,6 @@ Lex.prototype.erase = function (){
this.opacity = 1
this.build()
}
-Lex.prototype.fill = function(lex){
- this.fg = lex.fg
- this.bg = lex.bg
- this.char = lex.char
- this.opacity = lex.opacity
- this.build()
-}
Lex.prototype.eq = function(lex){
return lex && this.fg == lex.fg && this.bg == lex.bg && this.char == lex.char
}
diff --git a/js/matrix.js b/js/matrix.js
index 4c8976c..275e6b6 100644
--- a/js/matrix.js
+++ b/js/matrix.js
@@ -112,7 +112,7 @@ Matrix.prototype.fill = function(lex){
this.char = lex.char
this.opacity = lex.opacity
this.forEach(function(el,x,y){
- el.fill(lex)
+ el.assign(lex)
el.build()
})
}
diff --git a/js/ui/brush.js b/js/ui/brush.js
index 8cc858f..668538f 100644
--- a/js/ui/brush.js
+++ b/js/ui/brush.js
@@ -41,7 +41,7 @@ var brush = (function(){
}
else {
fillColor = brush.bg
- lex.fill(brush)
+ lex.assign(brush)
}
brush.focus(x, y)
})
@@ -55,7 +55,7 @@ var brush = (function(){
lex.clear()
}
else {
- lex.fill(brush)
+ lex.assign(brush)
}
brush.focus(x, y)
})