... then it does show in the center, but in the left corner the icon of the TaskDialog can be seen, which won't disappear, even when the user closes the dialog (Android-Pozicio02-2023-01-04_17-58-17x.png screenshot).
If I use "TaskDialog.Visible := False;", it won't help.
How can I center it in the middle of the screen on Android, so as the icon won't be shown? Thank you!
Typically on mobile devices the form takes up the screen so tdpOwnerFormCenter and tdpScreenCenter is not used in those cases. However, on mobile devices the dialog should be centered by default. This clearly does not happen when you create the dialog with a nil parent and we'll need to allocate time to investigate this.
In the meantime, you can just create the TTMSFNCTaskDialog with DialogParent, but don't assign DialogParent to TTMSFNCTaskDialog.Parent. This should result in the dialog being shown on the screen center.
Thank you that worked!
I don't know if I should open a new ticket for this question:
On Android the TaskDialog doesn't seem to be "dialog": the user can click on any control on the window which is under the dialog. Is there a workaround?
According to this piece of source, ShowModal doesn't work with mobiles:
{$IFNDEF FMXMOBILE}
try
Result := FDialogForm.ShowModal;
finally
FDialogForm.Free;
end;
{$ENDIF}
On mobile platforms (Android and iOS) the dialog is handled a bit differently but it should be modal by default. While you can see what controls are on the form when the dialog is shown, you should not be able to interact with those controls.
Is this not the case for you? We cannot reproduce the incorrect behavior here. Do you have a small sample application or code snippet that can reproduce this outside of your application?