Changeset 12673
- Timestamp:
- 02/23/08 22:29:50 (3 months ago)
- Files:
-
- 1 modified
-
dojox/trunk/gfx/vml.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
dojox/trunk/gfx/vml.js
r12663 r12673 77 77 h = parseFloat(this.rawNode.style.height), 78 78 c = isNaN(w) ? 1 : 2 * f.r / w; 79 a = new Array(f.colors.length); 79 a = []; 80 // add a color at the offset 0 (1 in VML coordinates) 81 if(f.colors[0].offset > 0){ 82 a.push({offset: 1, color: dojox.gfx.normalizeColor(f.colors[0].color)}); 83 } 80 84 // massage colors 81 85 dojo.forEach(f.colors, function(v, i){ 82 a [i] = {offset: 1 - v.offset * c, color: dojox.gfx.normalizeColor(v.color)};86 a.push({offset: 1 - v.offset * c, color: dojox.gfx.normalizeColor(v.color)}); 83 87 }); 84 88 i = a.length - 1; … … 98 102 for(; i >= 0; --i){ 99 103 s.push(a[i].offset.toFixed(8) + " " + a[i].color.toHex()); 100 }101 if(a[0].offset < 1){102 s.push("1 " + a[0].color.toHex());103 104 } 104 105 fo = this.rawNode.fill;