use of android.hardware.location.IFusedLocationHardwareSink in project android_frameworks_base by ResurrectionRemix.
the class FlpHardwareProvider method maybeSendCapabilities.
private void maybeSendCapabilities() {
IFusedLocationHardwareSink sink;
boolean haveBatchingCapabilities;
int batchingCapabilities;
synchronized (mLocationSinkLock) {
sink = mLocationSink;
haveBatchingCapabilities = mHaveBatchingCapabilities;
batchingCapabilities = mBatchingCapabilities;
}
try {
if (sink != null && haveBatchingCapabilities) {
sink.onCapabilities(batchingCapabilities);
}
} catch (RemoteException e) {
Log.e(TAG, "RemoteException calling onLocationAvailable");
}
}
use of android.hardware.location.IFusedLocationHardwareSink in project android_frameworks_base by DirtyUnicorns.
the class FlpHardwareProvider method maybeSendCapabilities.
private void maybeSendCapabilities() {
IFusedLocationHardwareSink sink;
boolean haveBatchingCapabilities;
int batchingCapabilities;
synchronized (mLocationSinkLock) {
sink = mLocationSink;
haveBatchingCapabilities = mHaveBatchingCapabilities;
batchingCapabilities = mBatchingCapabilities;
}
try {
if (sink != null && haveBatchingCapabilities) {
sink.onCapabilities(batchingCapabilities);
}
} catch (RemoteException e) {
Log.e(TAG, "RemoteException calling onLocationAvailable");
}
}
use of android.hardware.location.IFusedLocationHardwareSink in project android_frameworks_base by DirtyUnicorns.
the class FlpHardwareProvider method onLocationReport.
/**
* Private callback functions used by FLP HAL.
*/
// FlpCallbacks members
private void onLocationReport(Location[] locations) {
for (Location location : locations) {
location.setProvider(LocationManager.FUSED_PROVIDER);
// set the elapsed time-stamp just as GPS provider does
location.setElapsedRealtimeNanos(SystemClock.elapsedRealtimeNanos());
}
IFusedLocationHardwareSink sink;
synchronized (mLocationSinkLock) {
sink = mLocationSink;
}
try {
if (sink != null) {
sink.onLocationAvailable(locations);
}
} catch (RemoteException e) {
Log.e(TAG, "RemoteException calling onLocationAvailable");
}
}
use of android.hardware.location.IFusedLocationHardwareSink in project android_frameworks_base by crdroidandroid.
the class FlpHardwareProvider method onLocationReport.
/**
* Private callback functions used by FLP HAL.
*/
// FlpCallbacks members
private void onLocationReport(Location[] locations) {
for (Location location : locations) {
location.setProvider(LocationManager.FUSED_PROVIDER);
// set the elapsed time-stamp just as GPS provider does
location.setElapsedRealtimeNanos(SystemClock.elapsedRealtimeNanos());
}
IFusedLocationHardwareSink sink;
synchronized (mLocationSinkLock) {
sink = mLocationSink;
}
try {
if (sink != null) {
sink.onLocationAvailable(locations);
}
} catch (RemoteException e) {
Log.e(TAG, "RemoteException calling onLocationAvailable");
}
}
use of android.hardware.location.IFusedLocationHardwareSink in project android_frameworks_base by crdroidandroid.
the class FlpHardwareProvider method maybeSendCapabilities.
private void maybeSendCapabilities() {
IFusedLocationHardwareSink sink;
boolean haveBatchingCapabilities;
int batchingCapabilities;
synchronized (mLocationSinkLock) {
sink = mLocationSink;
haveBatchingCapabilities = mHaveBatchingCapabilities;
batchingCapabilities = mBatchingCapabilities;
}
try {
if (sink != null && haveBatchingCapabilities) {
sink.onCapabilities(batchingCapabilities);
}
} catch (RemoteException e) {
Log.e(TAG, "RemoteException calling onLocationAvailable");
}
}
Aggregations