UIAlertController
andのデフォルトのスタイルを使用していますUIAlertAction
が、スクリーンショットのように白い背景に白いテキストが表示されます
これが私のコードです:
UIAlertController *alert = [UIAlertController alertControllerWithTitle:nil message:nil preferredStyle:UIAlertControllerStyleActionSheet];
UIAlertAction* defaultAction = [UIAlertAction actionWithTitle:@"0237826726" style:UIAlertActionStyleDefault
handler:^(UIAlertAction * action) {
[self callPlaceNumber:@"0237826726"];
}];
[alert addAction:defaultAction];
UIAlertAction* cancel = [UIAlertAction actionWithTitle:@"Cancel" style:UIAlertActionStyleDefault
handler:^(UIAlertAction * action) {
[alert dismissViewControllerAnimated:YES completion:nil];
}];
[alert addAction:cancel];
[self presentViewController:alert animated:YES completion:nil];
tintColor
問題を検索したところ、次のように追加できることがわかりましたが、機能UIAlertController
しませんでした。
alert.view.tintColor = [UIColor blackColor];
これは正常な動作ですか、それとも私のコードに何か問題がありますか?