Commit c56b4499 authored by Felix Paul Kühne's avatar Felix Paul Kühne
Browse files

browsing: save some selector dispatches

parent 62fcee43
......@@ -59,9 +59,10 @@
NSString *imageSize;
if (sizes != nil) {
if (sizes.count > 1) {
NSUInteger count = sizes.count;
if (count > 1) {
imageSize = sizes[1];
} else if (sizes.count > 0) {
} else if (count > 0) {
imageSize = sizes.firstObject;
}
}
......@@ -102,9 +103,10 @@
NSString *imageSize;
if (sizes != nil) {
if (sizes.count > 1) {
NSUInteger count = sizes.count;
if (count > 1) {
imageSize = sizes[1];
} else if (sizes.count > 0) {
} else if (count > 0) {
imageSize = sizes.firstObject;
}
}
......
......@@ -131,7 +131,8 @@
browsingCell.titleLabel.font = [UIFont preferredFontForTextStyle:UIFontTextStyleCaption2];
browsingCell.subtitle = [self.discoveryController titleForSection:discoveryIndexPath.section];
browsingCell.subtitleLabel.font = [UIFont preferredFontForTextStyle:UIFontTextStyleCaption1];
browsingCell.thumbnailImage = service.icon ? service.icon : [UIImage imageNamed:@"serverIcon"];
UIImage *serviceIcon = service.icon;
browsingCell.thumbnailImage = serviceIcon ? serviceIcon : [UIImage imageNamed:@"serverIcon"];
return browsingCell;
}
......@@ -186,7 +187,6 @@
UIAlertController *alertController = [UIAlertController alertControllerWithTitle:NSLocalizedString(@"CONNECT_TO_SERVER", nil)
message:login.address preferredStyle:UIAlertControllerStyleAlert];
NSURLComponents *components = [[NSURLComponents alloc] init];
components.scheme = login.protocolIdentifier;
components.host = login.address;
......@@ -195,7 +195,6 @@
NSString *accountName = [SSKeychain accountsForService:serviceIdentifier].firstObject[kSSKeychainAccountKey];
NSString *password = [SSKeychain passwordForService:serviceIdentifier account:accountName];
__block UITextField *usernameField = nil;
__block UITextField *passwordField = nil;
[alertController addTextFieldWithConfigurationHandler:^(UITextField * _Nonnull textField) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment