diff --git a/PCCPDemo/PCCPDemo.xcodeproj/project.pbxproj b/PCCPDemo/PCCPDemo.xcodeproj/project.pbxproj index 0f3bb45..ed0247c 100644 --- a/PCCPDemo/PCCPDemo.xcodeproj/project.pbxproj +++ b/PCCPDemo/PCCPDemo.xcodeproj/project.pbxproj @@ -177,7 +177,6 @@ DFCBC6191B05909100A4642E /* Sources */, DFCBC61A1B05909100A4642E /* Frameworks */, DFCBC61B1B05909100A4642E /* Resources */, - F5C9A9ED0B8FEF5CEFE1FFBD /* [CP] Embed Pods Frameworks */, 5E26DEDFEC3B4C1740FEC7D0 /* [CP] Copy Pods Resources */, ); buildRules = ( @@ -273,7 +272,7 @@ files = ( ); inputPaths = ( - "${SRCROOT}/Pods/Target Support Files/Pods-PCCPDemo/Pods-PCCPDemo-resources.sh", + "${PODS_ROOT}/Target Support Files/Pods-PCCPDemo/Pods-PCCPDemo-resources.sh", "${PODS_ROOT}/Phone-Country-Code-and-Flags/Phone-Country-Code-and-Flags.bundle", ); name = "[CP] Copy Pods Resources"; @@ -282,22 +281,7 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PCCPDemo/Pods-PCCPDemo-resources.sh\"\n"; - showEnvVarsInLog = 0; - }; - F5C9A9ED0B8FEF5CEFE1FFBD /* [CP] Embed Pods Frameworks */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputPaths = ( - ); - name = "[CP] Embed Pods Frameworks"; - outputPaths = ( - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PCCPDemo/Pods-PCCPDemo-frameworks.sh\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-PCCPDemo/Pods-PCCPDemo-resources.sh\"\n"; showEnvVarsInLog = 0; }; /* End PBXShellScriptBuildPhase section */ diff --git a/PCCPDemo/PCCPDemo/ViewController.m b/PCCPDemo/PCCPDemo/ViewController.m index 6ce97f5..648c032 100644 --- a/PCCPDemo/PCCPDemo/ViewController.m +++ b/PCCPDemo/PCCPDemo/ViewController.m @@ -30,6 +30,7 @@ - (IBAction)pick:(id)sender { }]; [vc setIsUsingChinese:[_langSwitch selectedSegmentIndex] == 1]; UINavigationController *naviVC = [[UINavigationController alloc] initWithRootViewController:vc]; + naviVC.modalPresentationStyle = UIModalPresentationFullScreen; [self presentViewController:naviVC animated:YES completion:NULL]; } diff --git a/PCCPDemo/Podfile.lock b/PCCPDemo/Podfile.lock index a06579a..093c987 100644 --- a/PCCPDemo/Podfile.lock +++ b/PCCPDemo/Podfile.lock @@ -4,9 +4,13 @@ PODS: DEPENDENCIES: - Phone-Country-Code-and-Flags +SPEC REPOS: + trunk: + - Phone-Country-Code-and-Flags + SPEC CHECKSUMS: Phone-Country-Code-and-Flags: 19b303483d6e14091a1e3a404ec2aac8f08a985c PODFILE CHECKSUM: 3ee83dbaa9563a8a1cbe84460b2f403e47e7db92 -COCOAPODS: 1.4.0 +COCOAPODS: 1.8.4 diff --git a/PhoneCountryCodePicker/PCCPViewController.m b/PhoneCountryCodePicker/PCCPViewController.m index 0eb0baa..384ed02 100644 --- a/PhoneCountryCodePicker/PCCPViewController.m +++ b/PhoneCountryCodePicker/PCCPViewController.m @@ -189,9 +189,14 @@ -(NSString *)tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteg } - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { - UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"cellIdentifier" forIndexPath:indexPath]; + UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"cellIdentifier"];//[tableView dequeueReusableCellWithIdentifier:@"cellIdentifier" forIndexPath:indexPath]; + + cell.preservesSuperviewLayoutMargins = NO; + cell.separatorInset = UIEdgeInsetsZero; + cell.layoutMargins = UIEdgeInsetsZero; + if (!cell) { - cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"cellIdentifier"]; + cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"cellIdentifier"]; } if (_PCCs) { NSDictionary * countryDic = [_PCCs valueForKey:[_keys objectAtIndex:[indexPath section]]][indexPath.row]; @@ -202,6 +207,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N [[cell textLabel] setText:countryDic[@"country_en"]]; } [[cell imageView] setImage:[PCCPViewController imageForCountryCode:countryDic[@"country_code"]]]; + [[cell detailTextLabel] setText:[NSString stringWithFormat:@"+%@",countryDic[@"phone_code"]]]; return cell; } return cell;;