aboutsummaryrefslogtreecommitdiffstats
path: root/src/location-corelocation.m
diff options
context:
space:
mode:
authorJon Lund Steffensen <jonlst@gmail.com>2014-12-31 00:11:24 -0500
committerJon Lund Steffensen <jonlst@gmail.com>2015-01-04 16:32:47 -0500
commit799b08214dffc3c86e30c4547acd9015078a18ac (patch)
treefd01ab4421eee6bff66495431de5fb00b047245b /src/location-corelocation.m
parentMerge changes from 1.10 release branch (diff)
downloadredshift-ng-799b08214dffc3c86e30c4547acd9015078a18ac.tar.gz
redshift-ng-799b08214dffc3c86e30c4547acd9015078a18ac.tar.bz2
redshift-ng-799b08214dffc3c86e30c4547acd9015078a18ac.tar.xz
Add location_t type with lat/lon fields
Diffstat (limited to 'src/location-corelocation.m')
-rw-r--r--src/location-corelocation.m7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/location-corelocation.m b/src/location-corelocation.m
index edf3e45..2f1768d 100644
--- a/src/location-corelocation.m
+++ b/src/location-corelocation.m
@@ -25,6 +25,7 @@
#import <CoreLocation/CoreLocation.h>
#include "location-corelocation.h"
+#include "redshift.h"
#include <stdio.h>
@@ -143,7 +144,7 @@ location_corelocation_set_option(void *state,
int
location_corelocation_get_location(void *state,
- float *lat, float *lon)
+ location_t *location)
{
int result = -1;
@@ -153,8 +154,8 @@ location_corelocation_get_location(void *state,
CFRunLoopRun();
if (delegate.success) {
- *lat = delegate.latitude;
- *lon = delegate.longitude;
+ location->lat = delegate.latitude;
+ location->lon = delegate.longitude;
result = 0;
}
}