Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#91 Fixes missplacement of progress view on iOS 10 #93

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions KVNProgress.podspec
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
Pod::Spec.new do |s|
s.name = "KVNProgress"
s.version = "2.3.1"
s.summary = "A full screen progress view for iOS 7"
s.version = "2.3.2"
s.summary = "A full screen progress view for iOS 8"

s.homepage = "https://github.com/kevin-hirsch/KVNProgress"
s.license = { :type => "MIT", :file => "LICENSE" }
s.author = { "Kevin Hirsch" => "kevinh6113@hotmail.com" }
s.social_media_url = "http://twitter.com/kevinh6113"

s.platform = :ios, '7.0'
s.platform = :ios, '8.0'
s.source = {
:git => "https://github.com/kevin-hirsch/KVNProgress.git",
:tag => s.version.to_s
Expand Down
362 changes: 298 additions & 64 deletions KVNProgress.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0800"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "D91CFF8E1DBFA6D500A5FAF6"
BuildableName = "KVNProgress.framework"
BlueprintName = "KVNPogress-iOS"
ReferencedContainer = "container:KVNProgress.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
<AdditionalOptions>
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "D91CFF8E1DBFA6D500A5FAF6"
BuildableName = "KVNProgress.framework"
BlueprintName = "KVNPogress-iOS"
ReferencedContainer = "container:KVNProgress.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "D91CFF8E1DBFA6D500A5FAF6"
BuildableName = "KVNProgress.framework"
BlueprintName = "KVNPogress-iOS"
ReferencedContainer = "container:KVNProgress.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "811DD2EAD9760EB797B92FF1"
BuildableName = "libPods-KVNProgressTests.a"
BlueprintIdentifier = "C8F5D1B08CB228925F02D89C41DED6D0"
BuildableName = "Pods_KVNProgressTests.framework"
BlueprintName = "Pods-KVNProgressTests"
ReferencedContainer = "container:Pods/Pods.xcodeproj">
</BuildableReference>
Expand All @@ -29,8 +29,8 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "0AA0DCE61930DFAD00FDD29F"
BuildableName = "KVNProgress.app"
BlueprintName = "KVNProgress"
BuildableName = "KVNProgressDemo.app"
BlueprintName = "KVNProgressDemo"
ReferencedContainer = "container:KVNProgress.xcodeproj">
</BuildableReference>
</BuildActionEntry>
Expand All @@ -51,10 +51,10 @@
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
skipped = "NO">
Expand All @@ -71,47 +71,50 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "0AA0DCE61930DFAD00FDD29F"
BuildableName = "KVNProgress.app"
BlueprintName = "KVNProgress"
BuildableName = "KVNProgressDemo.app"
BlueprintName = "KVNProgressDemo"
ReferencedContainer = "container:KVNProgress.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "0AA0DCE61930DFAD00FDD29F"
BuildableName = "KVNProgress.app"
BlueprintName = "KVNProgress"
BuildableName = "KVNProgressDemo.app"
BlueprintName = "KVNProgressDemo"
ReferencedContainer = "container:KVNProgress.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "0AA0DCE61930DFAD00FDD29F"
BuildableName = "KVNProgress.app"
BlueprintName = "KVNProgress"
BuildableName = "KVNProgressDemo.app"
BlueprintName = "KVNProgressDemo"
ReferencedContainer = "container:KVNProgress.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
Expand Down
6 changes: 5 additions & 1 deletion KVNProgress/Classes/KVNProgress.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@

#import <UIKit/UIKit.h>

#import "KVNProgressConfiguration.h"
#import <KVNProgress/KVNProgressConfiguration.h>
#import <KVNProgress/KVNRotationViewController.h>
#import <KVNProgress/UIImage+KVNImageEffects.h>
#import <KVNProgress/UIImage+KVNEmpty.h>
#import <KVNProgress/UIColor+KVNContrast.h>

typedef NS_ENUM(NSUInteger, KVNProgressStyle) {
KVNProgressStyleHidden,
Expand Down
6 changes: 6 additions & 0 deletions KVNProgress/Classes/KVNProgress.m
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,12 @@ - (void)applicationDidBecomeActive
// Re-starts the infinite animation
[self animateCircleWithInfiniteLoop];
}

// set constraints again, because in iOS 10 the constraints get lost when the app is sent in background
if (self.superview && self.constraintsToSuperview) {
[self.superview removeConstraints:self.constraintsToSuperview];
[self.superview addConstraints:self.constraintsToSuperview];
}
}

- (void)orientationDidChange:(NSNotification *)notification {
Expand Down
10 changes: 10 additions & 0 deletions KVNProgress/Demo/Images.xcassets/AppIcon.appiconset/Contents.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"size" : "29x29",
"idiom" : "iphone",
Expand Down
6 changes: 3 additions & 3 deletions KVNProgress/KVNProgress-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
<key>CFBundleName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>2.3.1</string>
<string>2.3.2</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>241</string>
<string>253</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIMainStoryboardFile</key>
Expand Down
3 changes: 1 addition & 2 deletions KVNProgressTests/KVNProgressTests.m
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
#import <Specta/Specta.h>
#import <Expecta/Expecta.h>
#import <FBSnapshotTestCase/FBSnapshotTestCase.h>
#import <Expecta+Snapshots/EXPMatchers+FBSnapshotTest.h>

#import "KVNProgress.h"

Expand Down Expand Up @@ -70,4 +69,4 @@
});


SpecEnd
SpecEnd
2 changes: 1 addition & 1 deletion KVNProgressTests/KVNUIColor+KVNContrastSpec.m
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
// Copyright 2015 Pinch. All rights reserved.
//

#import "Specta.h"
#import <Specta/Specta.h>
#import <Expecta/Expecta.h>
#import "UIColor+KVNContrast.h"

Expand Down
13 changes: 11 additions & 2 deletions Podfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
platform :ios, '7.0'
platform :ios, '8.0'
use_frameworks!

target 'KVNProgress' do
target 'KVNProgressDemo' do

end

Expand All @@ -12,3 +13,11 @@ target 'KVNProgressTests' do
pod 'OCMock'
end

post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['SWIFT_VERSION'] = '3.0'
end
end
end

33 changes: 20 additions & 13 deletions Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
PODS:
- Expecta (0.4.0)
- Expecta+Snapshots (1.3.2):
- Expecta (~> 0.3)
- FBSnapshotTestCase (= 1.6)
- FBSnapshotTestCase (1.6)
- OCMock (3.1.2)
- Specta (0.5.0)
- Expecta (1.0.5)
- Expecta+Snapshots (3.0.0):
- Expecta (~> 1.0)
- FBSnapshotTestCase/Core (~> 2.0)
- Specta (~> 1.0)
- FBSnapshotTestCase (2.1.4):
- FBSnapshotTestCase/SwiftSupport (= 2.1.4)
- FBSnapshotTestCase/Core (2.1.4)
- FBSnapshotTestCase/SwiftSupport (2.1.4):
- FBSnapshotTestCase/Core
- OCMock (3.3.1)
- Specta (1.0.5)

DEPENDENCIES:
- Expecta
Expand All @@ -15,10 +20,12 @@ DEPENDENCIES:
- Specta

SPEC CHECKSUMS:
Expecta: 392a6b5bfb9f4097e47dd8064d9b732079490332
Expecta+Snapshots: 40c5ec43b43da3bae957f14fed5dc9177d08ec8b
FBSnapshotTestCase: 9d5fe43b29ae3a0ed8fc829477971b281038f748
OCMock: a10ea9f0a6e921651f96f78b6faee95ebc813b92
Specta: eb90708ed77569bbda089f8ead10bb99b8e9489e
Expecta: e1c022fcd33910b6be89c291d2775b3fe27a89fe
Expecta+Snapshots: c343f410c7a6392f3e22e78f94c44b6c0749a516
FBSnapshotTestCase: '094f9f314decbabe373b87cc339bea235a63e07a'
OCMock: f3f61e6eaa16038c30caa5798c5e49d3307b6f22
Specta: ac94d110b865115fe60ff2c6d7281053c6f8e8a2

COCOAPODS: 0.35.0
PODFILE CHECKSUM: 335f8e7f75e518cf9dd2d90f2a134cec59371c12

COCOAPODS: 1.1.1