This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
extension UIView { | |
convenience init(_ maskIntoConstraints: Bool) { | |
self.init() | |
self.translatesAutoresizingMaskIntoConstraints = maskIntoConstraints | |
} | |
} | |
extension UILabel { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-(NSString *)pickerView:(UIPickerView *)pickerView titleForRow:(NSInteger)row forComponent:(NSInteger)component { | |
NSArray *letters = @[@"C", @"D", @"F", @"G", @"J", @"K", @"M", @"Z"]; | |
return [NSString stringWithFormat:@"%@", letters[row]]; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSArray *answersArray = [Answers allObjects]; //however these are fetched | |
NSMutableArray *answerObjects = [[NSMutableArray alloc] init]; | |
//populate answerObjects array | |
for (Answer *answer in answersArray) { | |
PFObject *answerObject = [PFObject objectWithClassName:@"Answer"]; | |
[answerObject setValue:answer.correct forKey:@"Correct"]; | |
//set clue id, user, and other values |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath { | |
return 44.0f; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath { | |
return 44.0f; | |
} |