summaryrefslogtreecommitdiffstats
path: root/camera
diff options
context:
space:
mode:
authorRuben Brunk <rubenbrunk@google.com>2015-03-20 22:15:57 -0700
committerRuben Brunk <rubenbrunk@google.com>2015-03-31 12:11:10 -0700
commit36597b241c59eba7e55d5150092947a748c5e9cb (patch)
treebf174c4f6c45a2a5abfb3852effb567d5b653843 /camera
parentac41a6f253a69671f6e018fcc84daf0030615ca9 (diff)
downloadframeworks_av-36597b241c59eba7e55d5150092947a748c5e9cb.zip
frameworks_av-36597b241c59eba7e55d5150092947a748c5e9cb.tar.gz
frameworks_av-36597b241c59eba7e55d5150092947a748c5e9cb.tar.bz2
camera2: Enforce client eviction on user switch.
Bug: 19186859 Change-Id: I172a2ce46c8e8a131ae7e8dd99d60c5f4f0d6668
Diffstat (limited to 'camera')
-rw-r--r--camera/ICameraService.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/camera/ICameraService.cpp b/camera/ICameraService.cpp
index 63c82cc..51a775b 100644
--- a/camera/ICameraService.cpp
+++ b/camera/ICameraService.cpp
@@ -302,6 +302,15 @@ public:
status_t res = data.readInt32();
return res;
}
+
+ virtual void notifySystemEvent(int eventId, int arg0) {
+ Parcel data, reply;
+ data.writeInt32(eventId);
+ data.writeInt32(arg0);
+ remote()->transact(BnCameraService::NOTIFY_SYSTEM_EVENT, data, &reply,
+ IBinder::FLAG_ONEWAY);
+ }
+
};
IMPLEMENT_META_INTERFACE(CameraService, "android.hardware.ICameraService");
@@ -470,6 +479,13 @@ status_t BnCameraService::onTransact(
reply->writeInt32(status);
return NO_ERROR;
} break;
+ case NOTIFY_SYSTEM_EVENT: {
+ CHECK_INTERFACE(ICameraService, data, reply);
+ int eventId = data.readInt32();
+ int arg0 = data.readInt32();
+ notifySystemEvent(eventId, arg0);
+ return NO_ERROR;
+ } break;
default:
return BBinder::onTransact(code, data, reply, flags);
}