[Interest] Qt Positioning on iOS?
Israel Brewster
ijbrewster at alaska.edu
Sat Mar 7 01:16:51 CET 2020
Ok, clearing everything and trying again seems to have worked. Guess something got stuck somewhere along the line. I still have to test if geofencing will work with the app in the background though. Thanks!
---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
Fairbanks AK 99775-7320
Work: 907-474-5172
cell: 907-328-9145
> On Mar 6, 2020, at 9:30 AM, ekke <ekke at ekkes-corner.org> wrote:
>
> you should add something like this into your info.plist:
>
> <key>NSLocationWhenInUseUsageDescription</key>
> <string>$(PRODUCT_NAME) uses Location to get Weather Data for current Location</string>
> <key>“NSLocationAlwaysAndWhenInUseUsageDescription”</key>
> <string>$(PRODUCT_NAME) uses Location to get Weather Data for current Location</string>
>
> Am 06.03.20 um 19:08 schrieb Israel Brewster:
>> Simple question: how do I get Qt Positioning (C++) to work on iOS (current versions of everything)? I tried the code on the Qt Positioning page, and apparently the various createDefaultSource() calls all worked (I tried both QGeoPositionInfoSource and QGeoAreaMonitorSource), in that they returned non-zero pointers, but from what I can tell nothing happens after calling startUpdates(), requestUpdate(), or startMonitoring(), as appropriate for the source in question - no callbacks are ever called, including the error callback. Checking the result of error() on the source after I create it returns 3, which appears to be NoError. So there is no error, but I never seem to get any data either.
>>
>> I would note that iOS never asks me if I want to allow the program to use location data, which could account for the issue, but nothing in the documentation that I can find tells me how to get the OS to request this permission. Some googling finds an old thread on the subject, that refers to several keys in the Info.plist, but I tried adding those keys (and deleting the app from the phone/re-installing), and that didn’t seem to make any difference. What am I missing?
>>
>> ---
>> Israel Brewster
>> Software Engineer
>> Alaska Volcano Observatory
>> Geophysical Institute - UAF
>> 2156 Koyukuk Drive
>> Fairbanks AK 99775-7320
>> Work: 907-474-5172
>> cell: 907-328-9145
>>
>>
>>
>> _______________________________________________
>> Interest mailing list
>> Interest at qt-project.org <mailto:Interest at qt-project.org>
>> https://lists.qt-project.org/listinfo/interest <https://lists.qt-project.org/listinfo/interest>
>
> _______________________________________________
> Interest mailing list
> Interest at qt-project.org <mailto:Interest at qt-project.org>
> https://lists.qt-project.org/listinfo/interest <https://lists.qt-project.org/listinfo/interest>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20200306/488e1a8f/attachment.html>
More information about the Interest
mailing list