Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(44)

Side by Side Diff: chrome/browser/ui/cocoa/spinner_view.mm

Issue 2257553002: Fix OSX 10.12 compilation errors in chrome/browser/ui. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Moved 10.12 SDK defines to one header. Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/browser/ui/cocoa/info_bubble_window.mm ('k') | chrome/browser/ui/cocoa/sprite_view.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import "chrome/browser/ui/cocoa/spinner_view.h" 5 #import "chrome/browser/ui/cocoa/spinner_view.h"
6 6
7 #import <QuartzCore/QuartzCore.h> 7 #import <QuartzCore/QuartzCore.h>
8 8
9 #include "base/mac/sdk_forward_declarations.h" 9 #include "base/mac/sdk_forward_declarations.h"
10 #include "base/mac/scoped_cftyperef.h" 10 #include "base/mac/scoped_cftyperef.h"
(...skipping 13 matching lines...) Expand all
24 const CGFloat kArcLength = 58.9; 24 const CGFloat kArcLength = 58.9;
25 const CGFloat kArcStrokeWidth = 3.0; 25 const CGFloat kArcStrokeWidth = 3.0;
26 const CGFloat kArcAnimationTime = 1.333; 26 const CGFloat kArcAnimationTime = 1.333;
27 const CGFloat kArcStartAngle = kDegrees180; 27 const CGFloat kArcStartAngle = kDegrees180;
28 const CGFloat kArcEndAngle = (kArcStartAngle + kDegrees270); 28 const CGFloat kArcEndAngle = (kArcStartAngle + kDegrees270);
29 const CGFloat kRotationTime = 1.56863; 29 const CGFloat kRotationTime = 1.56863;
30 NSString* const kSpinnerAnimationName = @"SpinnerAnimationName"; 30 NSString* const kSpinnerAnimationName = @"SpinnerAnimationName";
31 NSString* const kRotationAnimationName = @"RotationAnimationName"; 31 NSString* const kRotationAnimationName = @"RotationAnimationName";
32 } 32 }
33 33
34 @interface SpinnerView () { 34 @interface SpinnerView () <CALayerDelegate> {
35 base::scoped_nsobject<CAAnimationGroup> spinnerAnimation_; 35 base::scoped_nsobject<CAAnimationGroup> spinnerAnimation_;
36 base::scoped_nsobject<CABasicAnimation> rotationAnimation_; 36 base::scoped_nsobject<CABasicAnimation> rotationAnimation_;
37 CAShapeLayer* shapeLayer_; // Weak. 37 CAShapeLayer* shapeLayer_; // Weak.
38 CALayer* rotationLayer_; // Weak. 38 CALayer* rotationLayer_; // Weak.
39 } 39 }
40 @end 40 @end
41 41
42 42
43 @implementation SpinnerView 43 @implementation SpinnerView
44 44
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 [rotationLayer_ addAnimation:rotationAnimation_.get() 293 [rotationLayer_ addAnimation:rotationAnimation_.get()
294 forKey:kRotationAnimationName]; 294 forKey:kRotationAnimationName];
295 } 295 }
296 } else { 296 } else {
297 [shapeLayer_ removeAllAnimations]; 297 [shapeLayer_ removeAllAnimations];
298 [rotationLayer_ removeAllAnimations]; 298 [rotationLayer_ removeAllAnimations];
299 } 299 }
300 } 300 }
301 301
302 @end 302 @end
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/info_bubble_window.mm ('k') | chrome/browser/ui/cocoa/sprite_view.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698