diff options
author | Jason Tholstrup <jthol@google.com> | 2016-03-15 14:02:58 -0700 |
---|---|---|
committer | Jason Tholstrup <jthol@google.com> | 2016-03-15 17:32:48 -0700 |
commit | e4c731ea3ed22615783efb02818b0b3d184bba33 (patch) | |
tree | 24a306693365dc2851fe09db05df47f2f77d3e84 /tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/KitchenSinkActivity.java | |
parent | d3de8bdde16e2fe8c877397cbd7ea730eb82c3e0 (diff) | |
download | Car-e4c731ea3ed22615783efb02818b0b3d184bba33.tar.gz |
Car support lib changes for shared support lib
- remove IBinder from onServiceConnected
- Add CarNotConnected exceptions to android.car.support methods
- various type cleanup
bug: 27679766
Change-Id: I58335da8296ec83ad2d6ffe76ba18d54ea8563a0
Diffstat (limited to 'tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/KitchenSinkActivity.java')
-rw-r--r-- | tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/KitchenSinkActivity.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/KitchenSinkActivity.java b/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/KitchenSinkActivity.java index 60aafe8557..f2e6e0ea48 100644 --- a/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/KitchenSinkActivity.java +++ b/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/KitchenSinkActivity.java @@ -35,6 +35,7 @@ import android.os.IBinder; import android.support.car.Car; import android.support.car.CarAppContextManager; import android.support.car.CarNotConnectedException; +import android.support.car.CarNotSupportedException; import android.support.car.ServiceConnectionListener; import android.support.car.app.menu.CarDrawerActivity; import android.support.car.app.menu.CarMenu; @@ -158,7 +159,7 @@ public class KitchenSinkActivity extends CarDrawerActivity { private final ServiceConnectionListener mServiceConnectionListener = new ServiceConnectionListener() { @Override - public void onServiceConnected(ComponentName name, IBinder service) { + public void onServiceConnected(ComponentName name) { Log.d(TAG, "Connected to Car Service"); try { mCameraManager = (CarCameraManager) mCarApi.getCarManager(android.car.Car @@ -174,6 +175,8 @@ public class KitchenSinkActivity extends CarDrawerActivity { (CarAppContextManager) mCarApi.getCarManager(Car.APP_CONTEXT_SERVICE); } catch (CarNotConnectedException e) { Log.e(TAG, "Car is not connected!"); + } catch (CarNotSupportedException e) { + Log.e(TAG, "Car is not supported!"); } } |