I have put together a sample programme for a problem with Android 10, which fails to get GPS data and cannot take pictures.
The permissions have been correctly set up.
The programme from which the sample has been taken works fine on Android 14 and 15, but not on 10. This demo only handles GPS data, not photos.
Well, I have tried to cut down the GPS problem to bedrock, and hope I may have succeeded.
This is as small as I can get it, and it now crashes on both android 10 and android 15.
The start button runs:
if FFusedLocation = nil then
FFusedLocation := TFusedLocation.Create(Self, true);
FFusedLocation.Start(FFOpt);
and after successfully navigating this it crashes
in Androidapi.JNI.Location.pas, libe 1227:
function TAndroidWindowHandle.TFormViewListener.onTouchEvent(event: JMotionEvent): Boolean;
begin
Result := FOwner.MotionManager.HandleMotionEvent(event);
end;
with a strange box labelled “Source file not found rtti_raw_invoke.s”
Just a polite tip - attaching zip files of source is a really bad idea. Most of us will not be prepared to download zip files due to the rare but not impossible chance the zip file contains something that could affect our systems.
Far better to share it on something like GitHub (you can make it private and then invite people to respond and add them to the repo if necessary) or you can share it as a GitHub Gist: https://gist.github.com which will allow you to keep it semi-secret but allow anyone with the link to view the code.
At Embarcadero and Idera it would be considered bad practice to download a zip file from a public source without taking a number of steps to protect our machine and exhausting all other possibilities first. From some sources it may even be blocked by our IT.
Ian, Where can I find instructions on how to use Github? I have only used it once, to download Kastri, and found it quite an unfriendly platform, no doubt due to unfamiliarity. Has anyone put together manual, or is it a matter of getting in, trying multiple ideas until one works?
That’s scarey! At the same time, my Delphi has decided not to use my splash screen (though the “icons” page looks properly set up), and I get occasional error messages from the debugger asking me to send the log files (what and where are these?) to Embarcadero.
Looks as though I will have to completely reinstal Delphi again, re-download and reinstal Kastri, and see if any of that helps. I’ll get back to you in a week.