Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Reset size of labels after overlay was shrinked, fixes #36

  • Loading branch information...
commit 3b86c7425790e6105ae420adf58ea1d7d6e42cb5 1 parent fd5f31c
@myell0w authored
Showing with 8 additions and 1 deletion.
  1. +8 −1 MTStatusBarOverlay.m
View
9 MTStatusBarOverlay.m
@@ -408,7 +408,6 @@ - (id)initWithFrame:(CGRect)frame {
// the hidden status label at the beginning
hiddenStatusLabel_ = statusLabel2_;
-
progress_ = 1.0;
progressView_ = [[UIImageView alloc] initWithFrame:statusBarBackgroundImageView_.frame];
progressView_.opaque = NO;
@@ -918,6 +917,14 @@ - (void)setShrinked:(BOOL)shrinked animated:(BOOL)animated {
self.statusLabel1.hidden = NO;
self.statusLabel2.hidden = NO;
+
+ CGRect frame = self.statusLabel1.frame;
+ frame.size.width = self.backgroundView.frame.size.width-60.f;
+ self.statusLabel1.frame = frame;
+
+ frame = self.statusLabel2.frame;
+ frame.size.width = self.backgroundView.frame.size.width-60.f;
+ self.statusLabel2.frame = frame;
}
// update status bar background
Please sign in to comment.
Something went wrong with that request. Please try again.