Skip to content
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
20 changes: 2 additions & 18 deletions PCCPDemo/PCCPDemo.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,6 @@
DFCBC6191B05909100A4642E /* Sources */,
DFCBC61A1B05909100A4642E /* Frameworks */,
DFCBC61B1B05909100A4642E /* Resources */,
F5C9A9ED0B8FEF5CEFE1FFBD /* [CP] Embed Pods Frameworks */,
5E26DEDFEC3B4C1740FEC7D0 /* [CP] Copy Pods Resources */,
);
buildRules = (
Expand Down Expand Up @@ -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";
Expand All @@ -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 */
Expand Down
1 change: 1 addition & 0 deletions PCCPDemo/PCCPDemo/ViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -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];
}

Expand Down
6 changes: 5 additions & 1 deletion PCCPDemo/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -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
10 changes: 8 additions & 2 deletions PhoneCountryCodePicker/PCCPViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -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];
Expand All @@ -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;;
Expand Down