Skip to content

Commit

Permalink
Fix objc bridging issue.
Browse files Browse the repository at this point in the history
  • Loading branch information
WenchaoD committed Sep 29, 2017
1 parent c50f092 commit 933cc54
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 6 deletions.
4 changes: 2 additions & 2 deletions FSPagerView/FSPagerView.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@
PRODUCT_BUNDLE_IDENTIFIER = com.wenchaod.FSPagerView;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_VERSION = 3.0;
SWIFT_VERSION = 4.0;
};
name = Debug;
};
Expand All @@ -322,7 +322,7 @@
PRODUCT_BUNDLE_IDENTIFIER = com.wenchaod.FSPagerView;
PRODUCT_NAME = "$(TARGET_NAME)";
SKIP_INSTALL = YES;
SWIFT_VERSION = 3.0;
SWIFT_VERSION = 4.0;
};
name = Release;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,12 +257,14 @@
F9C694481E40C6C1007084B6 = {
CreatedOnToolsVersion = 8.2.1;
DevelopmentTeam = HZF422TY46;
LastSwiftMigration = 0900;
ProvisioningStyle = Automatic;
TestTargetID = F9EC37181E304A830022B6D6;
};
F9EC37181E304A830022B6D6 = {
CreatedOnToolsVersion = 8.2.1;
DevelopmentTeam = HZF422TY46;
LastSwiftMigration = 0900;
ProvisioningStyle = Automatic;
};
};
Expand Down Expand Up @@ -384,7 +386,8 @@
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 3.0;
SWIFT_SWIFT3_OBJC_INFERENCE = On;
SWIFT_VERSION = 4.0;
TEST_TARGET_NAME = "FSPagerViewExample-Objc";
};
name = Debug;
Expand All @@ -400,7 +403,8 @@
PRODUCT_BUNDLE_IDENTIFIER = "com.wenchaod.FSPagerViewExample-ObjcUITests";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
SWIFT_VERSION = 3.0;
SWIFT_SWIFT3_OBJC_INFERENCE = On;
SWIFT_VERSION = 4.0;
TEST_TARGET_NAME = "FSPagerViewExample-Objc";
};
name = Release;
Expand Down Expand Up @@ -517,7 +521,8 @@
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = "com.wenchaod.FSPagerView-Objc";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 3.0;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 4.0;
};
name = Debug;
};
Expand All @@ -530,7 +535,8 @@
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = "com.wenchaod.FSPagerView-Objc";
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 3.0;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 4.0;
};
name = Release;
};
Expand Down
1 change: 1 addition & 0 deletions Sources/FSPageViewTransformer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ open class FSPagerViewTransformer: NSObject {
open var minimumScale: CGFloat = 0.65
open var minimumAlpha: CGFloat = 0.6

@objc
public init(type: FSPagerViewTransformerType) {
self.type = type
switch type {
Expand Down
1 change: 1 addition & 0 deletions Sources/FSPagerView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,7 @@ open class FSPagerView: UIView,UICollectionViewDataSource,UICollectionViewDelega
}

/// The transformer of the pager view.
@objc
open var transformer: FSPagerViewTransformer? {
didSet {
self.transformer?.pagerView = self
Expand Down
2 changes: 2 additions & 0 deletions Sources/FSPagerViewCell.swift
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import UIKit
open class FSPagerViewCell: UICollectionViewCell {

/// Returns the label used for the main textual content of the pager view cell.
@objc
open var textLabel: UILabel? {
if let _ = _textLabel {
return _textLabel
Expand All @@ -32,6 +33,7 @@ open class FSPagerViewCell: UICollectionViewCell {
}

/// Returns the image view of the pager view cell. Default is nil.
@objc
open var imageView: UIImageView? {
if let _ = _imageView {
return _imageView
Expand Down

0 comments on commit 933cc54

Please sign in to comment.