Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 160c5c34b6 | |||
| a6638c0108 |
@@ -79,8 +79,8 @@ android {
|
|||||||
applicationId "com.ariacockpit"
|
applicationId "com.ariacockpit"
|
||||||
minSdkVersion rootProject.ext.minSdkVersion
|
minSdkVersion rootProject.ext.minSdkVersion
|
||||||
targetSdkVersion rootProject.ext.targetSdkVersion
|
targetSdkVersion rootProject.ext.targetSdkVersion
|
||||||
versionCode 903
|
versionCode 904
|
||||||
versionName "0.0.9.3"
|
versionName "0.0.9.4"
|
||||||
// Fallback fuer Libraries mit Product Flavors
|
// Fallback fuer Libraries mit Product Flavors
|
||||||
missingDimensionStrategy 'react-native-camera', 'general'
|
missingDimensionStrategy 'react-native-camera', 'general'
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "aria-cockpit",
|
"name": "aria-cockpit",
|
||||||
"version": "0.0.9.3",
|
"version": "0.0.9.4",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"android": "react-native run-android",
|
"android": "react-native run-android",
|
||||||
|
|||||||
@@ -725,17 +725,23 @@ const ChatScreen: React.FC = () => {
|
|||||||
|
|
||||||
// GPS-Position holen (optional)
|
// GPS-Position holen (optional)
|
||||||
const getCurrentLocation = useCallback((): Promise<{ lat: number; lon: number } | null> => {
|
const getCurrentLocation = useCallback((): Promise<{ lat: number; lon: number } | null> => {
|
||||||
if (!gpsEnabled) return Promise.resolve(null);
|
if (!gpsEnabled) {
|
||||||
|
console.log('[GPS] gpsEnabled=false → kein Standort');
|
||||||
|
return Promise.resolve(null);
|
||||||
|
}
|
||||||
|
|
||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
Geolocation.getCurrentPosition(
|
Geolocation.getCurrentPosition(
|
||||||
(position) => {
|
(position) => {
|
||||||
resolve({
|
const loc = {
|
||||||
lat: position.coords.latitude,
|
lat: position.coords.latitude,
|
||||||
lon: position.coords.longitude,
|
lon: position.coords.longitude,
|
||||||
});
|
};
|
||||||
|
console.log('[GPS] Position: lat=%s lon=%s', loc.lat, loc.lon);
|
||||||
|
resolve(loc);
|
||||||
},
|
},
|
||||||
(_error) => {
|
(error) => {
|
||||||
|
console.warn('[GPS] getCurrentPosition Fehler:', error?.code, error?.message);
|
||||||
resolve(null);
|
resolve(null);
|
||||||
},
|
},
|
||||||
{ enableHighAccuracy: false, timeout: 5000 },
|
{ enableHighAccuracy: false, timeout: 5000 },
|
||||||
|
|||||||
Reference in New Issue
Block a user