Merge branch 'charlesmchen/uploadProgressTweaks'

pull/1/head
Matthew Chen 8 years ago
commit e11381ffd7

@ -47,7 +47,8 @@ NS_ASSUME_NONNULL_BEGIN
[superview.layer addSublayer:_maskLayer]; [superview.layer addSublayer:_maskLayer];
const CGFloat progressWidth = round(superview.frame.size.width * 0.45f); const CGFloat progressWidth = round(superview.frame.size.width * 0.45f);
const CGFloat progressHeight = round(progressWidth * 0.11f); const CGFloat progressHeight = round(MIN(superview.frame.size.height * 0.5f,
progressWidth * 0.09f));
CGRect progressFrame = CGRectMake(round((superview.frame.size.width - progressWidth) * 0.5f), CGRect progressFrame = CGRectMake(round((superview.frame.size.width - progressWidth) * 0.5f),
round((superview.frame.size.height - progressHeight) * 0.5f), round((superview.frame.size.height - progressHeight) * 0.5f),
progressWidth, progressWidth,

@ -79,8 +79,8 @@ NS_ASSUME_NONNULL_BEGIN
- (void)update - (void)update
{ {
CGFloat kBorderThickness = self.bounds.size.height * 0.15f; CGFloat kBorderThickness = self.bounds.size.height * 0.1f;
CGFloat kOuterRadius = self.bounds.size.height * 0.3f; CGFloat kOuterRadius = self.bounds.size.height * 0.25f;
CGFloat kInnerRadius = kOuterRadius - kBorderThickness; CGFloat kInnerRadius = kOuterRadius - kBorderThickness;
// We want to slightly overlap the border with the progress // We want to slightly overlap the border with the progress
// to achieve a clean effect. // to achieve a clean effect.

Loading…
Cancel
Save