comparison dwt/graphics/Pattern.d @ 7:e831403a80a9

Add 'cast' to casts
author Frank Benoit <benoit@tionex.de>
date Wed, 27 Aug 2008 14:30:35 +0200
parents 1a8b3cb347e0
children 93b13b15f0b1
comparison
equal deleted inserted replaced
6:b903c16b6f48 7:e831403a80a9
164 this.color2 = color2.handle; 164 this.color2 = color2.handle;
165 this.alpha1 = alpha1; 165 this.alpha1 = alpha1;
166 this.alpha2 = alpha2; 166 this.alpha2 = alpha2;
167 NSColor start = NSColor.colorWithDeviceRed(color1.handle[0], color1.handle[1], color1.handle[2], alpha1 / 255f); 167 NSColor start = NSColor.colorWithDeviceRed(color1.handle[0], color1.handle[1], color1.handle[2], alpha1 / 255f);
168 NSColor end = NSColor.colorWithDeviceRed(color2.handle[0], color2.handle[1], color2.handle[2], alpha2 / 255f); 168 NSColor end = NSColor.colorWithDeviceRed(color2.handle[0], color2.handle[1], color2.handle[2], alpha2 / 255f);
169 gradient = ((NSGradient)new NSGradient().alloc()).initWithStartingColor(start, end); 169 gradient = (cast(NSGradient)new NSGradient().alloc()).initWithStartingColor(start, end);
170 init(); 170 init();
171 } 171 }
172 172
173 void destroy() { 173 void destroy() {
174 if (color !is null) color.release(); 174 if (color !is null) color.release();