Skip to content

Commit

Permalink
Swift 5.0 support
Browse files Browse the repository at this point in the history
  • Loading branch information
andreamazz committed Mar 26, 2019
1 parent f444668 commit 1f55685
Show file tree
Hide file tree
Showing 31 changed files with 920 additions and 852 deletions.
2 changes: 1 addition & 1 deletion .swift-version
@@ -1 +1 @@
4.2
5.0
2 changes: 1 addition & 1 deletion AMPopTip.podspec
Expand Up @@ -14,7 +14,7 @@ Pod::Spec.new do |s|
s.author = { "Andrea Mazzini" => "andrea.mazzini@gmail.com" }
s.source = { :git => "https://github.com/andreamazz/AMPopTip.git", :tag => s.version }
s.platform = :ios, '8.0'
s.swift_version = '4.2'
s.swift_version = '5.0'
s.source_files = 'Source', '*.{swift}'
s.requires_arc = true
s.social_media_url = 'https://twitter.com/theandreamazz'
Expand Down
11 changes: 6 additions & 5 deletions AMPopTip.xcodeproj/project.pbxproj
Expand Up @@ -119,10 +119,11 @@
};
buildConfigurationList = 653C20221EC351010007D179 /* Build configuration list for PBXProject "AMPopTip" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = 653C201E1EC351010007D179;
productRefGroup = 653C20291EC351010007D179 /* Products */;
Expand Down Expand Up @@ -214,7 +215,7 @@
SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 4.2;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
VERSION_INFO_PREFIX = "";
Expand Down Expand Up @@ -269,7 +270,7 @@
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
SWIFT_VERSION = 4.2;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
VERSIONING_SYSTEM = "apple-generic";
Expand All @@ -294,7 +295,7 @@
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
SKIP_INSTALL = YES;
SWIFT_VERSION = 4.2;
SWIFT_VERSION = 5.0;
};
name = Debug;
};
Expand All @@ -315,7 +316,7 @@
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
SKIP_INSTALL = YES;
SWIFT_VERSION = 4.2;
SWIFT_VERSION = 5.0;
};
name = Release;
};
Expand Down
8 changes: 4 additions & 4 deletions Demo/Podfile.lock
@@ -1,5 +1,5 @@
PODS:
- AMPopTip (3.4.0)
- AMPopTip (3.6.0)
- FBSnapshotTestCase (2.1.4):
- FBSnapshotTestCase/SwiftSupport (= 2.1.4)
- FBSnapshotTestCase/Core (2.1.4)
Expand All @@ -21,7 +21,7 @@ DEPENDENCIES:
- Quick (= 1.1.0)

SPEC REPOS:
https://github.com/CocoaPods/Specs.git:
https://github.com/cocoapods/specs.git:
- FBSnapshotTestCase
- Nimble
- Nimble-Snapshots
Expand All @@ -32,12 +32,12 @@ EXTERNAL SOURCES:
:path: "../"

SPEC CHECKSUMS:
AMPopTip: 80cf814fe063b054af0ea20d2e4c404faf6bbc6d
AMPopTip: ebba6ae1859d3b22a68562e1baf8ea0e159b545e
FBSnapshotTestCase: 094f9f314decbabe373b87cc339bea235a63e07a
Nimble: c53e6903fee94041b90ded74f135820437d8bf59
Nimble-Snapshots: e743439f26c2fa99d8f7e0d7c01c99bcb40aa6f2
Quick: dafc587e21eed9f4cab3249b9f9015b0b7a7f71d

PODFILE CHECKSUM: 68d6239712fba8e0da2721828fdb2901c0ef7977

COCOAPODS: 1.5.0
COCOAPODS: 1.5.3
6 changes: 3 additions & 3 deletions Demo/Pods/Local Podspecs/AMPopTip.podspec.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions Demo/Pods/Manifest.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1,667 changes: 859 additions & 808 deletions Demo/Pods/Pods.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion Demo/Pods/Target Support Files/AMPopTip/Info.plist

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 13 additions & 4 deletions Demo/PopTip Demo.xcodeproj/project.pbxproj
Expand Up @@ -272,7 +272,7 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0830;
LastUpgradeCheck = 0900;
LastUpgradeCheck = 1020;
ORGANIZATIONNAME = "Andrea Mazzini";
TargetAttributes = {
653472341EB7B89C002DA5DA = {
Expand All @@ -298,7 +298,7 @@
};
buildConfigurationList = 653472301EB7B89C002DA5DA /* Build configuration list for PBXProject "PopTip Demo" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Expand Down Expand Up @@ -526,13 +526,15 @@
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
Expand Down Expand Up @@ -583,13 +585,15 @@
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
Expand Down Expand Up @@ -632,8 +636,9 @@
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE = "3173682a-5d59-4178-a2b9-6c42435a39d7";
PROVISIONING_PROFILE_SPECIFIER = Development;
SWIFT_COMPILATION_MODE = wholemodule;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 4.2;
SWIFT_VERSION = 5.0;
};
name = Debug;
};
Expand All @@ -651,7 +656,7 @@
PROVISIONING_PROFILE = "3173682a-5d59-4178-a2b9-6c42435a39d7";
PROVISIONING_PROFILE_SPECIFIER = Development;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 4.2;
SWIFT_VERSION = 5.0;
};
name = Release;
};
Expand All @@ -667,6 +672,7 @@
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 5.0;
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/PopTip Demo.app/PopTip Demo";
};
name = Debug;
Expand All @@ -683,6 +689,7 @@
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 5.0;
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/PopTip Demo.app/PopTip Demo";
};
name = Release;
Expand All @@ -698,6 +705,7 @@
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 5.0;
};
name = Debug;
};
Expand All @@ -712,6 +720,7 @@
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 5.0;
};
name = Release;
};
Expand Down
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0900"
LastUpgradeVersion = "1020"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand All @@ -26,7 +26,6 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
Expand Down Expand Up @@ -66,7 +65,6 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
34 changes: 21 additions & 13 deletions Demo/PopTip Demo/Assets.xcassets/AppIcon.appiconset/Contents.json
@@ -1,54 +1,62 @@
{
"info" : {
"author" : "appicon",
"version" : 1
},
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"filename" : "AppIcon-20.0x20.0@2x.png",
"idiom" : "iphone",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"filename" : "AppIcon-20.0x20.0@3x.png",
"idiom" : "iphone",
"scale" : "3x"
},
{
"size" : "29x29",
"filename" : "AppIcon-29.0x29.0@2x.png",
"idiom" : "iphone",
"filename" : "AMPopTip-58.png",
"scale" : "2x"
},
{
"size" : "29x29",
"filename" : "AppIcon-29.0x29.0@3x.png",
"idiom" : "iphone",
"filename" : "AMPopTip-87.png",
"scale" : "3x"
},
{
"size" : "40x40",
"filename" : "AppIcon-40.0x40.0@2x.png",
"idiom" : "iphone",
"filename" : "AMPopTip-80.png",
"scale" : "2x"
},
{
"size" : "40x40",
"filename" : "AppIcon-40.0x40.0@3x.png",
"idiom" : "iphone",
"filename" : "AMPopTip-121.png",
"scale" : "3x"
},
{
"size" : "60x60",
"filename" : "AppIcon-60.0x60.0@2x.png",
"idiom" : "iphone",
"filename" : "AMPopTip-120.png",
"scale" : "2x"
},
{
"size" : "60x60",
"filename" : "AppIcon-60.0x60.0@3x.png",
"idiom" : "iphone",
"filename" : "AMPopTip-180.png",
"scale" : "3x"
},
{
"size" : "1024x1024",
"filename" : "AppIcon-1024.0x1024.0@1x.png",
"idiom" : "ios-marketing",
"scale" : "1x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
]
}
1 change: 1 addition & 0 deletions Demo/PopTip Demo/ViewController.swift
Expand Up @@ -93,6 +93,7 @@ class ViewController: UIViewController {
label.font = UIFont.systemFont(ofSize: 12)
customView.addSubview(label)
popTip.bubbleColor = UIColor(red: 0.95, green: 0.65, blue: 0.21, alpha: 1)
popTip.cornerRadius = 10
popTip.show(customView: customView, direction: .down, in: view, from: sender.frame)

popTip.entranceAnimationHandler = { [weak self] completion in
Expand Down

0 comments on commit 1f55685

Please sign in to comment.