mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 22:55:00 +00:00
+ Some iOS6 Fixes.
This commit is contained in:
@@ -180,7 +180,9 @@
|
|||||||
UIColor *color = [self colorAtPoint:point];
|
UIColor *color = [self colorAtPoint:point];
|
||||||
CGFloat alpha, white;
|
CGFloat alpha, white;
|
||||||
[color getWhite:&white alpha:&alpha];
|
[color getWhite:&white alpha:&alpha];
|
||||||
if (white || alpha){
|
NSLog(@"%f %f", alpha,white);
|
||||||
|
|
||||||
|
if ((int)white > 0 || (int)alpha > 0){
|
||||||
return self;
|
return self;
|
||||||
} else {
|
} else {
|
||||||
return nil;
|
return nil;
|
||||||
|
|||||||
@@ -177,13 +177,17 @@
|
|||||||
|
|
||||||
- (void)tapped:(UITapGestureRecognizer *)tapRecognizer {
|
- (void)tapped:(UITapGestureRecognizer *)tapRecognizer {
|
||||||
if (self.navigationController.navigationBarHidden){
|
if (self.navigationController.navigationBarHidden){
|
||||||
[[UIApplication sharedApplication] setStatusBarHidden:NO];
|
[UIView animateWithDuration:0.35f animations:^{
|
||||||
[self.navigationController setNavigationBarHidden:NO animated:YES];
|
[[UIApplication sharedApplication] setStatusBarHidden:NO];
|
||||||
|
[self.navigationController setNavigationBarHidden:NO animated:NO];
|
||||||
|
} completion:nil];
|
||||||
} else {
|
} else {
|
||||||
[self.navigationController setNavigationBarHidden:YES animated:YES];
|
[UIView animateWithDuration:0.35f animations:^{
|
||||||
[[UIApplication sharedApplication] setStatusBarHidden:YES];
|
[[UIApplication sharedApplication] setStatusBarHidden:YES];
|
||||||
|
[self.navigationController setNavigationBarHidden:YES animated:NO];
|
||||||
|
} completion:nil];
|
||||||
}
|
}
|
||||||
|
|
||||||
[self layoutViews];
|
[self layoutViews];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -308,23 +308,17 @@ typedef NS_ENUM(NSInteger, BITImageAnnotationViewControllerInteractionMode) {
|
|||||||
-(void)tapped:(UIGestureRecognizer *)tapRecognizer {
|
-(void)tapped:(UIGestureRecognizer *)tapRecognizer {
|
||||||
if (self.navigationController.navigationBarHidden){
|
if (self.navigationController.navigationBarHidden){
|
||||||
[UIView animateWithDuration:0.35f animations:^{
|
[UIView animateWithDuration:0.35f animations:^{
|
||||||
self.navigationController.navigationBar.alpha = 1;
|
[[UIApplication sharedApplication] setStatusBarHidden:NO];
|
||||||
|
[self.navigationController setNavigationBarHidden:NO animated:NO];
|
||||||
} completion:^(BOOL finished) {
|
} completion:^(BOOL finished) {
|
||||||
[self fitImageViewFrame];
|
[self fitImageViewFrame];
|
||||||
[self.navigationController setNavigationBarHidden:NO animated:NO];
|
|
||||||
[[UIApplication sharedApplication] setStatusBarHidden:NO];
|
|
||||||
}];
|
}];
|
||||||
} else {
|
} else {
|
||||||
[UIView animateWithDuration:0.35f animations:^{
|
[UIView animateWithDuration:0.35f animations:^{
|
||||||
self.navigationController.navigationBar.alpha = 0;
|
|
||||||
|
|
||||||
} completion:^(BOOL finished) {
|
|
||||||
[self.navigationController setNavigationBarHidden:YES animated:NO];
|
|
||||||
[[UIApplication sharedApplication] setStatusBarHidden:YES];
|
[[UIApplication sharedApplication] setStatusBarHidden:YES];
|
||||||
|
[self.navigationController setNavigationBarHidden:YES animated:NO];
|
||||||
|
} completion:^(BOOL finished) {
|
||||||
[self fitImageViewFrame];
|
[self fitImageViewFrame];
|
||||||
|
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user