Skip to content

Commit

Permalink
Merge pull request #15 from aldrincb/master
Browse files Browse the repository at this point in the history
Set iconImageView frame when iconStartSize is set
  • Loading branch information
callumboddy committed Feb 1, 2017
2 parents 8bb77bf + 72216b8 commit 2b3b7d1
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Classes/CBZRasterSplashView.m
Expand Up @@ -37,6 +37,13 @@ - (instancetype)initWithIconImage:(UIImage *)icon backgroundColor:(UIColor *)col
return self;
}

- (void)setIconStartSize:(CGSize)iconStartSize
{
[super setIconStartSize:iconStartSize];
self.iconImageView.frame = CGRectMake(0, 0, iconStartSize.width, iconStartSize.height);
self.iconImageView.center = self.center;
}

- (void)startAnimationWithCompletionHandler:(void (^)())completionHandler
{
__block __weak typeof(self) weakSelf = self;
Expand Down
7 changes: 7 additions & 0 deletions Pod/Classes/CBZRasterSplashView.m
Expand Up @@ -37,6 +37,13 @@ - (instancetype)initWithIconImage:(UIImage *)icon backgroundColor:(UIColor *)col
return self;
}

- (void)setIconStartSize:(CGSize)iconStartSize
{
[super setIconStartSize:iconStartSize];
self.iconImageView.frame = CGRectMake(0, 0, iconStartSize.width, iconStartSize.height);
self.iconImageView.center = self.center;
}

- (void)startAnimationWithCompletionHandler:(void (^)())completionHandler
{
__block __weak typeof(self) weakSelf = self;
Expand Down

0 comments on commit 2b3b7d1

Please sign in to comment.