Changeset 1007
- Timestamp:
- 07/31/08 04:02:25 (1 month ago)
- Files:
-
- branches/1.0.x/chrome/content/dta/manager.js (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/1.0.x/chrome/content/dta/manager.js
r942 r1007 628 628 629 629 case 'content-length': 630 this.contentlength = Number(aValue); 630 let contentlength = new Number(aValue); 631 if (contentLength > 0 && !isNaN(contentLength)) { 632 this.contentlength = Math.floor(contentLength); 633 } 631 634 break; 632 635 … … 982 985 get totalSize() { return this._totalSize; }, 983 986 set totalSize(nv) { 984 this._totalSize = nv; 987 if (this._totalsize == nv) { 988 return nv; 989 } 990 if (nv >= 0 && !isNaN(nv)) { 991 this._totalSize = Math.floor(nv); 992 } 985 993 this.invalidate(); 986 994 return this._totalSize; … … 2018 2026 if (visitor.contentlength > 0) { 2019 2027 d.totalSize = visitor.contentlength; 2020 } else { 2028 } 2029 else { 2021 2030 d.totalSize = 0; 2022 2031 }
