Skip to content

Commit

Permalink
Fixed some more warnings.
Browse files Browse the repository at this point in the history
  • Loading branch information
justinweiss committed Dec 5, 2016
1 parent 3eed7db commit ef6daeb
Show file tree
Hide file tree
Showing 7 changed files with 96 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Classes/DGSPhoneAppDelegate.m
Expand Up @@ -26,7 +26,7 @@ @interface DGSPhoneAppDelegate ()
// backgrounded, but I don't need to check if I already got push notifications.
// Unfortunately, there's no good activation hook method I can check to only
// check for outstanding notifications if we didn't receive a push notification.
@property (nonatomic) BOOL *receivedRemoteNotification;
@property (nonatomic) BOOL receivedRemoteNotification;
@end

@implementation DGSPhoneAppDelegate
Expand Down
1 change: 1 addition & 0 deletions Classes/Table Cells/BooleanCell.m
Expand Up @@ -12,6 +12,7 @@ - (id)init {
}

- (void)awakeFromNib {
[super awakeFromNib];
UISwitch *theSwitch = [[UISwitch alloc] initWithFrame:CGRectZero];
self.toggleSwitch = theSwitch;
self.accessoryView = theSwitch;
Expand Down
1 change: 1 addition & 0 deletions Classes/Table Cells/SelectCell.m
Expand Up @@ -25,6 +25,7 @@ - (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reus
}

- (void)awakeFromNib {
[super awakeFromNib];
self.picker = nil;
}

Expand Down
11 changes: 9 additions & 2 deletions Classes/Views/MessageView.m
Expand Up @@ -18,15 +18,19 @@ - (id)initWithFrame:(CGRect)frame {
}

- (void)awakeFromNib {
[super awakeFromNib];
self.showInputView = YES;
}

- (void)keyboardWillBeShown:(NSNotification *)aNotification {
CGSize kbSize = [[aNotification userInfo][UIKeyboardFrameBeginUserInfoKey] CGRectValue].size;
NSTimeInterval duration = [[aNotification userInfo][UIKeyboardAnimationDurationUserInfoKey] floatValue];
UIViewAnimationCurve curve = [[aNotification userInfo][UIKeyboardAnimationCurveUserInfoKey] intValue];

// see the discussion here: http://stackoverflow.com/questions/7327249/ios-how-to-convert-uiviewanimationcurve-to-uiviewanimationoptions#7327374
UIViewAnimationOptions options = curve << 16;

[UIView animateWithDuration:duration delay:0 options:curve animations:^(void) {
[UIView animateWithDuration:duration delay:0 options:options animations:^(void) {
self.messageInputView.frame = CGRectOffset(self.messageInputView.frame, 0, -kbSize.height);
} completion:nil];
}
Expand All @@ -35,8 +39,11 @@ - (void)keyboardWillBeHidden:(NSNotification *)aNotification {
CGSize kbSize = [[aNotification userInfo][UIKeyboardFrameBeginUserInfoKey] CGRectValue].size;
NSTimeInterval duration = [[aNotification userInfo][UIKeyboardAnimationDurationUserInfoKey] floatValue];
UIViewAnimationCurve curve = [[aNotification userInfo][UIKeyboardAnimationCurveUserInfoKey] intValue];

// see the discussion here: http://stackoverflow.com/questions/7327249/ios-how-to-convert-uiviewanimationcurve-to-uiviewanimationoptions#7327374
UIViewAnimationOptions options = curve << 16;

[UIView animateWithDuration:duration delay:0 options:curve animations:^(void) {
[UIView animateWithDuration:duration delay:0 options:options animations:^(void) {
self.messageInputView.frame = CGRectOffset(self.messageInputView.frame, 0, kbSize.height);
} completion:nil];
}
Expand Down
8 changes: 8 additions & 0 deletions DGS.entitlements
@@ -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>aps-environment</key>
<string>development</string>
</dict>
</plist>
2 changes: 1 addition & 1 deletion DGSPhone-Info.plist
Expand Up @@ -25,7 +25,7 @@
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>116</string>
<string>124</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSApplicationCategoryType</key>
Expand Down
80 changes: 75 additions & 5 deletions DGSPhone.xcodeproj/project.pbxproj
Expand Up @@ -141,6 +141,7 @@
DA419A6011BA0C0600B3050E /* FuegoBoard.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FuegoBoard.mm; sourceTree = "<group>"; };
DA419D4311BB2DA400B3050E /* CurrentGamesController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CurrentGamesController.h; sourceTree = "<group>"; };
DA419D4411BB2DA400B3050E /* CurrentGamesController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CurrentGamesController.m; sourceTree = "<group>"; };
DA427CF71DA0816F001E4304 /* DGS.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = DGS.entitlements; sourceTree = "<group>"; };
DA476A5214DA109F00AAF7E0 /* SenTestingKit.framework */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = wrapper.framework; name = SenTestingKit.framework; path = Library/Frameworks/SenTestingKit.framework; sourceTree = DEVELOPER_DIR; };
DA4BC703179517C900C74040 /* ExpandingLabelCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ExpandingLabelCell.h; sourceTree = "<group>"; };
DA4BC704179517C900C74040 /* ExpandingLabelCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ExpandingLabelCell.m; sourceTree = "<group>"; };
Expand Down Expand Up @@ -300,6 +301,7 @@
29B97314FDCFA39411CA2CEA /* CustomTemplate */ = {
isa = PBXGroup;
children = (
DA427CF71DA0816F001E4304 /* DGS.entitlements */,
DAEE341C15884ECA00300B29 /* Podfile */,
DADD1CE111FD3C43005922A3 /* FAQ.md */,
DADD1CDD11FD3C0B005922A3 /* Readme.md */,
Expand Down Expand Up @@ -612,8 +614,19 @@
29B97313FDCFA39411CA2CEA /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0720;
LastUpgradeCheck = 0800;
ORGANIZATIONNAME = "Justin Weiss";
TargetAttributes = {
1D6058900D05DD3D006BFB54 = {
DevelopmentTeam = SB3AKTYGF8;
ProvisioningStyle = Automatic;
SystemCapabilities = {
com.apple.Push = {
enabled = 1;
};
};
};
};
};
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "DGSPhone" */;
compatibilityVersion = "Xcode 3.2";
Expand Down Expand Up @@ -796,7 +809,11 @@
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_OBJC_ARC = YES;
CODE_SIGN_ENTITLEMENTS = DGS.entitlements;
CODE_SIGN_IDENTITY = "iPhone Distribution";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEVELOPMENT_TEAM = SB3AKTYGF8;
GCC_INLINES_ARE_PRIVATE_EXTERN = NO;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
Expand All @@ -822,6 +839,10 @@
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_OBJC_ARC = YES;
CODE_SIGN_ENTITLEMENTS = DGS.entitlements;
CODE_SIGN_IDENTITY = "iPhone Distribution";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
DEVELOPMENT_TEAM = SB3AKTYGF8;
GCC_INLINES_ARE_PRIVATE_EXTERN = NO;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = DGSPhone_Prefix.pch;
Expand All @@ -842,50 +863,95 @@
C01FCF4F08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Developer";
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_NO_COMMON_BLOCKS = YES;
GCC_PREPROCESSOR_DEFINITIONS = FUEGO_NDEBUG;
GCC_THUMB_SUPPORT = NO;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
ONLY_ACTIVE_ARCH = YES;
PROVISIONING_PROFILE = "";
SDKROOT = iphoneos;
};
name = Debug;
};
C01FCF5008A954540054247B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "iPhone Distribution: Justin Weiss (SB3AKTYGF8)";
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Distribution";
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_NO_COMMON_BLOCKS = YES;
GCC_PREPROCESSOR_DEFINITIONS = (
"$(inherited)",
NS_BLOCK_ASSERTIONS,
NDEBUG,
FUEGO_NDEBUG,
);
GCC_THUMB_SUPPORT = NO;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
PROVISIONING_PROFILE = "05b1e2ad-1db4-4a77-a4b3-30fbc01e7e9d";
SDKROOT = iphoneos;
};
name = Release;
};
DA667DC0125AE40300CA9A13 /* Adhoc */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_IDENTITY = "iPhone Distribution";
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_NO_COMMON_BLOCKS = YES;
GCC_THUMB_SUPPORT = NO;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
PROVISIONING_PROFILE = "";
SDKROOT = iphoneos;
};
name = Adhoc;
Expand All @@ -897,7 +963,11 @@
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_OBJC_ARC = YES;
CODE_SIGN_ENTITLEMENTS = DGS.entitlements;
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEVELOPMENT_TEAM = SB3AKTYGF8;
GCC_INLINES_ARE_PRIVATE_EXTERN = NO;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = DGSPhone_Prefix.pch;
Expand Down

0 comments on commit ef6daeb

Please sign in to comment.