0

ナビゲーションバーに「イベントの追加」タイトルが表示されない EKEventEditViewController に関して、この奇妙な問題があります。次のコードを使用して表示します。

[eventStore requestAccessToEntityType:EKEntityTypeEvent completion:^(BOOL granted, NSError *error) {
    if (!granted) { return; }
    
    __block EKEvent *calEvent = [EKEvent eventWithEventStore:eventStore];
    calEvent.title = self.event.title;
    calEvent.startDate = startDate;
    calEvent.endDate = endDate;
    calEvent.location = self.event.address.title;
    [calEvent setCalendar:[eventStore defaultCalendarForNewEvents]];
    
    __block EKEventEditViewController *eventViewController = [[EKEventEditViewController alloc] init];
    eventViewController.editViewDelegate = self;
    eventViewController.eventStore = eventStore;
    eventViewController.event = calEvent;
    dispatch_async(dispatch_get_main_queue(), ^{
        [self presentViewController:eventViewController animated:YES completion:nil];
    });
}];

結果は次のとおりです。 ここに画像の説明を入力

どんな助けでも大歓迎です。

4

1 に答える 1