projects
/
roojs1
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
209cfc4
)
Roo/util/Math.js
author
Alan Knowles
<alan@akbkhome.com>
Tue, 11 Jan 2011 07:11:09 +0000
(15:11 +0800)
committer
Alan Knowles
<alan@akbkhome.com>
Tue, 11 Jan 2011 07:11:09 +0000
(15:11 +0800)
Roo/util/Math.js
patch
|
blob
|
history
diff --git
a/Roo/util/Math.js
b/Roo/util/Math.js
index
df2b8c7
..
9190c20
100644
(file)
--- a/
Roo/util/Math.js
+++ b/
Roo/util/Math.js
@@
-161,8
+161,11
@@
Roo.util.Math.prototype = {
for(++l; --l; n[s](0));
return n;
},
- round : function(){
- if("_rounding" in this) return this;
+ round : function()
+ {
+
+ if("_rounding" in this) return this; // stop recursion..
+
var r = this.roundType, b = this._d, d, p, n, x;
for(this._rounding = true; this._f > 1 && !b[0]; --this._f, b.shift());
for(d = this._f, p = this.precision + d, n = b[p]; b.length > d && !b[b.length -1]; b.pop());