Skip to content
This repository has been archived by the owner on Sep 21, 2020. It is now read-only.

Update self compiler warnings #212

Open
wants to merge 1 commit 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
24 changes: 23 additions & 1 deletion CarbonKit.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@
A6DA8BCB1DAFE75B00F7B13B /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0730;
LastUpgradeCheck = 0930;
ORGANIZATIONNAME = "Ermal Kaleci";
TargetAttributes = {
A6DA8BD31DAFE75B00F7B13B = {
Expand Down Expand Up @@ -256,13 +256,23 @@
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
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_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;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
Expand Down Expand Up @@ -304,13 +314,23 @@
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
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_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;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
Expand Down Expand Up @@ -340,6 +360,7 @@
A6DA8BE91DAFE75B00F7B13B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "";
DEFINES_MODULE = YES;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
Expand All @@ -356,6 +377,7 @@
A6DA8BEA1DAFE75B00F7B13B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "";
DEFINES_MODULE = YES;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0900"
LastUpgradeVersion = "0930"
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 @@ -56,7 +55,6 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
Expand Down
20 changes: 10 additions & 10 deletions CarbonKit/CarbonSwipeRefresh.m
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ - (void)drawRect:(CGRect)rect {
- (void)didMoveToSuperview {
if (self.superview != nil) {
dispatch_once(&initConstraits, ^{
topConstrait = [NSLayoutConstraint constraintWithItem:self
self->topConstrait = [NSLayoutConstraint constraintWithItem:self
attribute:NSLayoutAttributeTop
relatedBy:NSLayoutRelationEqual
toItem:self.superview
Expand All @@ -222,7 +222,7 @@ - (void)didMoveToSuperview {
constant:0];

[self setTranslatesAutoresizingMaskIntoConstraints:NO];
[self.superview addConstraint:topConstrait];
[self.superview addConstraint:self->topConstrait];
[self.superview addConstraint:centerXConstrait];
});
}
Expand Down Expand Up @@ -308,19 +308,19 @@ - (void)observeValueForKeyPath:(NSString *)keyPath
pullState = PullStateRefreshing;
[UIView animateWithDuration:.2f
animations:^{
topConstrait.constant = 10 - marginTop;
self->topConstrait.constant = 10 - self->marginTop;
[self.superview layoutIfNeeded];
}];
[self startAnimating];
[self sendActionsForControlEvents:UIControlEventValueChanged];
} else {
[UIView animateWithDuration:0.2
animations:^{
topConstrait.constant = -50 - marginTop;
self->topConstrait.constant = -50 - self->marginTop;
[self.superview layoutIfNeeded];
}
completion:^(BOOL finished) {
pathLayer.strokeColor = ((UIColor *)self.colors[colorIndex]).CGColor;
self->pathLayer.strokeColor = ((UIColor *)self.colors[self->colorIndex]).CGColor;
}];
}
}
Expand Down Expand Up @@ -494,11 +494,11 @@ - (void)hideView {
completion:^(BOOL finished) {
[self endAnimating];

pullState = PullStateFinished;
colorIndex = 0;
pathLayer.strokeColor = ((UIColor *)self.colors[colorIndex]).CGColor;
self->pullState = PullStateFinished;
self->colorIndex = 0;
self->pathLayer.strokeColor = ((UIColor *)self.colors[self->colorIndex]).CGColor;

topConstrait.constant = -50 + marginTop;
self->topConstrait.constant = -50 + self->marginTop;
}];
}

Expand All @@ -513,7 +513,7 @@ - (void)startRefreshing {
self.layer.opacity = 1;
self.layer.transform = CATransform3DMakeScale(1, 1, 1);

topConstrait.constant = 10 - marginTop;
self->topConstrait.constant = 10 - self->marginTop;
[self layoutIfNeeded];

}
Expand Down
8 changes: 4 additions & 4 deletions CarbonKit/CarbonTabSwipeNavigation.m
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ - (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id<UIVi
[self syncIndicator];
[CATransaction commit];
} completion:^(id<UIViewControllerTransitionCoordinatorContext> _Nonnull context) {
isSwipeLocked = NO;
self->isSwipeLocked = NO;
}];
isSwipeLocked = YES;
[super viewWillTransitionToSize:size withTransitionCoordinator:coordinator];
Expand Down Expand Up @@ -177,8 +177,8 @@ - (void)moveToIndex:(NSUInteger)index withAnimation:(BOOL)animate {
self.pageViewController.view.userInteractionEnabled = NO;

id animateCompletionBlock = ^(BOOL finished) {
isSwipeLocked = NO;
selectedIndex = index;
self->isSwipeLocked = NO;
self->selectedIndex = index;
self.carbonSegmentedControl.userInteractionEnabled = YES;
self.pageViewController.view.userInteractionEnabled = YES;

Expand Down Expand Up @@ -218,7 +218,7 @@ - (void)syncIndicator {
previewsOffset = CGPointMake(offsetX, 0);
[UIView animateWithDuration:isLoaded ? 0.3 : 0
animations:^{
self.carbonTabSwipeScrollView.contentOffset = previewsOffset;
self.carbonTabSwipeScrollView.contentOffset = self->previewsOffset;
}];
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>