From 9777879583f9d05ee1fedc4d2c8664dc02a1f2c0 Mon Sep 17 00:00:00 2001 From: Alexsander Khitev Date: Tue, 5 Apr 2016 18:41:13 +0400 Subject: [PATCH] here was a mistake, when we opened the browser, and then turned the device activity light remained in the same place that looked incorrectly https://www.dropbox.com/s/mc55lvapyqaetpo/Simulator%20Screen%20Shot%20Apr%205%2C%202016%2C%202.29.37%20PM.png?dl=0 --- SKPhotoBrowser/SKIndicatorView.swift | 2 +- SKPhotoBrowser/SKZoomingScrollView.swift | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/SKPhotoBrowser/SKIndicatorView.swift b/SKPhotoBrowser/SKIndicatorView.swift index a7988df..fa6ff9d 100644 --- a/SKPhotoBrowser/SKIndicatorView.swift +++ b/SKPhotoBrowser/SKIndicatorView.swift @@ -16,7 +16,7 @@ class SKIndicatorView: UIActivityIndicatorView { override init(frame: CGRect) { super.init(frame: frame) - center = CGPoint(x: frame.width/2, y: frame.height/2) + center = CGPoint(x: frame.width / 2, y: frame.height / 2) activityIndicatorViewStyle = .WhiteLarge } diff --git a/SKPhotoBrowser/SKZoomingScrollView.swift b/SKPhotoBrowser/SKZoomingScrollView.swift index 05b6f98..d0b6dea 100644 --- a/SKPhotoBrowser/SKZoomingScrollView.swift +++ b/SKPhotoBrowser/SKZoomingScrollView.swift @@ -74,9 +74,13 @@ public class SKZoomingScrollView: UIScrollView, UIScrollViewDelegate, SKDetectin } // MARK: - override + public override func layoutSubviews() { tapView.frame = bounds + // + indicatorView.frame = frame + super.layoutSubviews() let boundsSize = bounds.size