Hi,
I am having a problem displaying a collection view modally.
Please see example: http://www.estateagentpro.com/iCL%20CollectionView%20Bug.zip
If you click on the button on the main screen and then the back button on the dialog and repeat this after a few times the app crashes.
If I remove the collection view from the dialog this does not happen.
Ken
Hi,
Thanks, I will come back and confirm.
I'm afraid that this does not cure the problem and still occurs after doing it a few times.
Just to confirm. I have modified:
destructor TTMSFMXNativeUICollectionView.Destroy;
...
if Assigned(FCollectionView) then
begin
FCollectionView.removeFromSuperview;
FCollectionView.release;
FCollectionView := nil;
end;
...
Interestingly enough if, instead of creating the collection view at design time, I create it programatically in the forms OnCreate event and dispose of it in the forms destructor I don't have the same problem even without the new line of code provided.
We have tested this here in the simulator. We will test it again on the device.
Thanks, yes, it is. I am using a device and it happens every time.
Sorry, I did not reply fully, sometimes it happens the 3rd time it's opened and others the 2nd time.
Is there any news on this as it is rather a show stopper for me? The good news is that this does not happen with a table view!
Hi,
Thanks, but I can see no mention of this in the documentation.
The same thing happens if I use Show rather than ShowModal. Is that not supported either?
The responsible developer will look into this upon return from winter holiday.
Thank you. So we are clear is that your way of saying that it won't be looked at until the New Year?
Yes
Hi,
Thanks, but in a large project this is a nightmare. I want to keep the code in seperate forms. I do not need to show them modally though.
You can add the collectionview on a separate form and then set the parent to the mainform if you need it, and toggle the visibility to show it. Using a modal form that creates/destroys the collection view is currently not supported. We will investigate here if we can add a non-visual component that handles multiple forms/frames.
Pieter,, thanks but as I said before this happens with Show as well as ShowModal so is not just a modal issue.
Yes, but it still creates and destroys the form. Currently, that's the issue for showing native controls.
Do you have any intention of trying to fix this?