Hallo,
ich bin gerade auf folgenden Bug in iOS 8 gestoßen, vielleicht hilft's ja den einen oder anderen und vermeidet graue Haare:
1. Gegeben eine iPad-Anwendung, basierend auf Master/Detail mit UISplitviewController, Deployment-Target ist iOS7, SDK ist iOS8.
2. Die Anwendung hat in der Toolbar des MasterViewControllers ein BarButtonItem. Mit Tap auf das Item wird ein UIActionSheet angezeigt.
3. Unter iOS7 funktioniert das in Landscape und Portrait.
4. Unter iOS8 bekomme ich in Portrait eine Exception:
5. In Landscape funktioniert's.
Blöd, also habe ich mir gedacht verwende ich eben unter iOS8 den neuen UIAlertController, da ist's aber genau andersrum. Der geht nicht in Landscape aber in Portrait
Da habe ich wieder eine Exception:
Das Dumme ist nur, der Lösungsvorschlag geht nicht. Da ich an den popoverPresentationController des UIAlertControllers gar nicht komme: Bei der Erzeugung ist er noch nil und später komme ich nicht mehr hin
Wie stellt Apple sich das vor, wie das gehen soll?
schönen
Gruß
gandhi
ich bin gerade auf folgenden Bug in iOS 8 gestoßen, vielleicht hilft's ja den einen oder anderen und vermeidet graue Haare:
1. Gegeben eine iPad-Anwendung, basierend auf Master/Detail mit UISplitviewController, Deployment-Target ist iOS7, SDK ist iOS8.
2. Die Anwendung hat in der Toolbar des MasterViewControllers ein BarButtonItem. Mit Tap auf das Item wird ein UIActionSheet angezeigt.
3. Unter iOS7 funktioniert das in Landscape und Portrait.
4. Unter iOS8 bekomme ich in Portrait eine Exception:
UIAlertController (<UIAlertController: 0xfb23ad0>) of style UIAlertControllerStyleActionSheet. The modalPresentationStyle of a UIAlertController with this style is UIModalPresentationPopover. You must provide location information for this popover through the alert controller's popoverPresentationController. You must provide either a sourceView and sourceRect or a barButtonItem. If this information is not known when you present the alert controller, you may provide it in the UIPopoverPresentationControllerDelegate method -prepareForPopoverPresentation.'
5. In Landscape funktioniert's.
Blöd, also habe ich mir gedacht verwende ich eben unter iOS8 den neuen UIAlertController, da ist's aber genau andersrum. Der geht nicht in Landscape aber in Portrait
Da habe ich wieder eine Exception:
*** Terminating app due to uncaught exception 'NSGenericException', reason: 'Your application has presented a UIAlertController (<UIAlertController: 0xe4085a0>) of style UIAlertControllerStyleActionSheet. The modalPresentationStyle of a UIAlertController with this style is UIModalPresentationPopover. You must provide location information for this popover through the alert controller's popoverPresentationController. You must provide either a sourceView and sourceRect or a barButtonItem. If this information is not known when you present the alert controller, you may provide it in the UIPopoverPresentationControllerDelegate method -prepareForPopoverPresentation.'
Das Dumme ist nur, der Lösungsvorschlag geht nicht. Da ich an den popoverPresentationController des UIAlertControllers gar nicht komme: Bei der Erzeugung ist er noch nil und später komme ich nicht mehr hin
Wie stellt Apple sich das vor, wie das gehen soll?
schönen
Gruß
gandhi