3737#import " NSObjectAdditions.h"
3838
3939#define PGAlertViewSize 100 .0f
40- #define PGMarginSize 4.0
40+ #define PGMarginSize 4 .0f
4141
4242@interface PGAlertView (Private)
4343
@@ -74,7 +74,7 @@ - (void)pushGraphic:(PGAlertGraphic *)aGraphic
7474 [self _updateCurrentGraphic ];
7575 }
7676 NSTimeInterval const fadeOutDelay = [_currentGraphic fadeOutDelay ];
77- if (fadeOutDelay >= 0.01 ) [self PG_performSelector: @selector (popGraphicIdenticalTo: ) withObject: _currentGraphic fireDate: nil interval: -fadeOutDelay options: PGCompareArgumentPointer];
77+ if (fadeOutDelay >= 0 .01f ) [self PG_performSelector: @selector (popGraphicIdenticalTo: ) withObject: _currentGraphic fireDate: nil interval: -fadeOutDelay options: PGCompareArgumentPointer];
7878 if (window && [[self window ] respondsToSelector: @selector (displayOverWindow: )]) [(PGBezelPanel *)[self window ] displayOverWindow: window];
7979}
8080- (void )popGraphic : (PGAlertGraphic *)aGraphic
@@ -138,7 +138,7 @@ - (void)_updateCurrentGraphic
138138 [_frameTimer invalidate ];
139139 _frameCount = 0 ;
140140 NSTimeInterval const animationDelay = [_currentGraphic animationDelay ];
141- _frameTimer = animationDelay > 0 ? [self PG_performSelector: @selector (animateOneFrame: ) withObject: self fireDate: nil interval: animationDelay options: PGRetainTarget] : nil ;
141+ _frameTimer = animationDelay > 0 . 0f ? [self PG_performSelector: @selector (animateOneFrame: ) withObject: self fireDate: nil interval: animationDelay options: PGRetainTarget] : nil ;
142142 [self setNeedsDisplay: YES ];
143143}
144144
@@ -259,22 +259,22 @@ - (void)drawInView:(PGAlertView *)anAlertView
259259 [[NSColor AE_bezelBackgroundColor ] set ];
260260 NSBezierPath *const path = [NSBezierPath bezierPath ];
261261 [path moveToPoint: centers[i]];
262- [path appendBezierPathWithArcWithCenter: centers[i] radius: 50 .0f * f startAngle: 90 * i endAngle: 90 * (i + 1 )];
262+ [path appendBezierPathWithArcWithCenter: centers[i] radius: 50 .0f * f startAngle: 90 . 0f * i endAngle: 90 . 0f * (i + 1 )];
263263 [path closePath ];
264264 [path fill ];
265265 }
266266
267267 NSShadow *const shadow = [[[NSShadow alloc ] init ] autorelease ];
268- [shadow setShadowBlurRadius: 4 ];
269- [shadow setShadowOffset: NSMakeSize (0 , -1 )];
268+ [shadow setShadowBlurRadius: 4 . 0f ];
269+ [shadow setShadowOffset: NSMakeSize (0 . 0f , -1 . 0f )];
270270 [shadow setShadowColor: [NSColor blackColor ]];
271271 [shadow set ];
272272}
273273- (void )flipHorizontally
274274{
275275 NSAffineTransform *const flip = [[[NSAffineTransform alloc ] init ] autorelease ];
276- [flip translateXBy: PGAlertViewSize yBy: 0 ];
277- [flip scaleXBy: -1 yBy: 1 ];
276+ [flip translateXBy: PGAlertViewSize yBy: 0 . 0f ];
277+ [flip scaleXBy: -1 . 0f yBy: 1 . 0f ];
278278 [flip concat ];
279279}
280280- (NSTimeInterval )fadeOutDelay
@@ -286,7 +286,7 @@ - (NSTimeInterval)fadeOutDelay
286286
287287- (NSTimeInterval )animationDelay
288288{
289- return 0 ;
289+ return 0 . 0f ;
290290}
291291- (unsigned )frameMax
292292{
@@ -321,15 +321,15 @@ - (void)drawInView:(PGAlertView *)anAlertView
321321 [[NSColor AE_bezelForegroundColor ] set ];
322322
323323 NSBezierPath *const arrow = [NSBezierPath bezierPath ];
324- [arrow appendBezierPathWithArcWithCenter: NSMakePoint (180 .0f * f, 150 .0f * f) radius: large startAngle: 315 endAngle: 45 ];
325- [arrow appendBezierPathWithArcWithCenter: NSMakePoint (140 .0f * f, 200 .0f * f) radius: small startAngle: 45 endAngle: 90 ];
326- [arrow appendBezierPathWithArcWithCenter: NSMakePoint (125 .0f * f, 200 .0f * f) radius: small startAngle: 90 endAngle: 180 ];
327- [arrow appendBezierPathWithArcWithCenter: NSMakePoint (115 .0f * f, 180 .0f * f) radius: small startAngle: 0 endAngle: 270 clockwise: YES ];
328- [arrow appendBezierPathWithArcWithCenter: NSMakePoint ( 75 .0f * f, 170 .0f * f) radius: small startAngle: 90 endAngle: 180 ];
329- [arrow appendBezierPathWithArcWithCenter: NSMakePoint ( 75 .0f * f, 130 .0f * f) radius: small startAngle: 180 endAngle: 270 ];
330- [arrow appendBezierPathWithArcWithCenter: NSMakePoint (115 .0f * f, 120 .0f * f) radius: small startAngle: 90 endAngle: 0 clockwise: YES ];
331- [arrow appendBezierPathWithArcWithCenter: NSMakePoint (125 .0f * f, 100 .0f * f) radius: small startAngle: 180 endAngle: 270 ];
332- [arrow appendBezierPathWithArcWithCenter: NSMakePoint (140 .0f * f, 100 .0f * f) radius: small startAngle: 270 endAngle: 315 ];
324+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint (180 .0f * f, 150 .0f * f) radius: large startAngle: 315 . 0f endAngle: 45 . 0f ];
325+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint (140 .0f * f, 200 .0f * f) radius: small startAngle: 45 . 0f endAngle: 90 . 0f ];
326+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint (125 .0f * f, 200 .0f * f) radius: small startAngle: 90 . 0f endAngle: 180 . 0f ];
327+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint (115 .0f * f, 180 .0f * f) radius: small startAngle: 0 . 0f endAngle: 270 . 0f clockwise: YES ];
328+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint ( 75 .0f * f, 170 .0f * f) radius: small startAngle: 90 . 0f endAngle: 180 . 0f ];
329+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint ( 75 .0f * f, 130 .0f * f) radius: small startAngle: 180 . 0f endAngle: 270 . 0f ];
330+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint (115 .0f * f, 120 .0f * f) radius: small startAngle: 90 . 0f endAngle: 0 . 0f clockwise: YES ];
331+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint (125 .0f * f, 100 .0f * f) radius: small startAngle: 180 . 0f endAngle: 270 . 0f ];
332+ [arrow appendBezierPathWithArcWithCenter: NSMakePoint (140 .0f * f, 100 .0f * f) radius: small startAngle: 270 . 0f endAngle: 315 . 0f ];
333333 [arrow fill ];
334334
335335 NSBezierPath *const wall = [NSBezierPath bezierPath ];
@@ -420,7 +420,7 @@ - (float)progress
420420}
421421- (void )setProgress : (float )progress
422422{
423- _progress = MIN (MAX (progress, 0 ), 1 );
423+ _progress = MIN (MAX (progress, 0 . 0f ), 1 . 0f );
424424}
425425
426426#pragma mark NSObject Protocol
@@ -460,7 +460,7 @@ - (NSTimeInterval)fadeOutDelay
460460
461461- (NSTimeInterval )animationDelay
462462{
463- return 1.0 / 12.0 ;
463+ return 1 .0f / 12 .0f ;
464464}
465465- (unsigned )frameMax
466466{
0 commit comments