Merge lp:~fboucault/camera-app/gps_work_with_no_altitude into lp:camera-app

Proposed by Florian Boucault
Status: Merged
Approved by: Arthur Mello
Approved revision: 438
Merged at revision: 439
Proposed branch: lp:~fboucault/camera-app/gps_work_with_no_altitude
Merge into: lp:camera-app
Diff against target: 21 lines (+4/-3)
1 file modified
ViewFinderOverlay.qml (+4/-3)
To merge this branch: bzr merge lp:~fboucault/camera-app/gps_work_with_no_altitude
Reviewer Review Type Date Requested Status
Arthur Mello (community) Approve
Review via email: mp+244113@code.launchpad.net

Commit message

Store location even if no valid altitude was provided.

To post a comment you must log in.
Revision history for this message
Arthur Mello (artmello) wrote :

lgtm

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'ViewFinderOverlay.qml'
2--- ViewFinderOverlay.qml 2014-12-05 18:43:54 +0000
3+++ ViewFinderOverlay.qml 2014-12-09 11:23:34 +0000
4@@ -405,13 +405,14 @@
5 var position = positionSource.position;
6 if (settings.gpsEnabled && positionSource.valid
7 && position.latitudeValid
8- && position.longitudeValid
9- && position.altitudeValid) {
10+ && position.longitudeValid) {
11 camera.imageCapture.setMetadata("GPSLatitude", position.coordinate.latitude);
12 camera.imageCapture.setMetadata("GPSLongitude", position.coordinate.longitude);
13- camera.imageCapture.setMetadata("GPSAltitude", position.coordinate.altitude);
14 camera.imageCapture.setMetadata("GPSTimeStamp", position.timestamp);
15 camera.imageCapture.setMetadata("GPSProcessingMethod", "GPS");
16+ if (position.altitudeValid) {
17+ camera.imageCapture.setMetadata("GPSAltitude", position.coordinate.altitude);
18+ }
19 }
20 if (main.contentExportMode) {
21 camera.imageCapture.captureToLocation(application.temporaryLocation);

Subscribers

People subscribed via source and target branches