Lessen dependency on the old SVMP Protocol code

Copied over the one SVMPSensorEventMessage we still use in the JNI code,
but strip it down to the bare minimum of code.

Change-Id: Ic057a2b5b6da4f966c7d60238b510cecc09a4679
Add missing type field to SVMPSensorEventMessage

Change-Id: I8c6e5e0d1b27d6613fca4204a45d0e4c2cc16f4d
Update event server for new video code

Add support for external fbstream server reachable via a UNIX socket
(eliminates the need for RTSP)

Change-Id: I2eb4e1b02b1250671d8f73a9e75e03a9a2505e7f
Handle STOP response. Send ACK for each video response.

Change-Id: I7b34fd5c9e2e0a5adb0eb3e40619945d75c58b77
Don't crash if WindowManager not ready

Change-Id: Idd89ad8ad3018a0bb0ed86bc4f8faf6c356f633e
Revert "Don't crash if WindowManager not ready"

This reverts commit 0ba76e176cd2d7fcdee7a12104f7247258dc961f


Having event server crash and be immediately restarted by init if the WindowManager isn't initialized is pretty well harmless. Fixing it uncovered some kind of nasty initialization race condition that completely breaks the unix sockets the event server uses to talk to fbstream and libsensors. /facepalm

Change-Id: Idf1cbc864d0f4b05fc524a6188167a548c1eab99
Add support for webrtc helper

Change-Id: I0a7d9dca53b309ee24935a0c2232b8649247ba68
Send a webrtc BYE to fbstream on client disconnect

If the client socket just dies, there's no way for fbstream to find out
that this happened, so it keeps blasting away with video.

Change-Id: I27105ea5512244af820f11c993b8376ceba27000
Converted EventServer to Android Service

EventServer now runs as a persistent system-level Service
It can request system-level permissions, and it has a Context to interact
with other apps

Change-Id: I5dd8a0349b173cd0e894b7a3fcffd8ea34c18af7
Added Rotation handling

Added code to process ROTATION_INFO Protobuf messages and send out ROTATION_CHANGED system broadcasts

Change-Id: I756284fbe4e9c8c7a571d749b61c848d3c68d780
Collapsed LocationHelper into EventServer

Removed LocationHelper app completely.
Now the EventServer is an Android service, it can communicate directly with
the LocationManager using Intent broadcasts.

Change-Id: Ic50d5be5375630f2b44982d713f2d1802ad123f7
Collapsed NetIntentsHelper into EventServer

Removed NetIntentsHelper app completely.
Now the EventServer is an Android service, it can communicate directly with
the NotificationManager using Intent broadcasts, it can intercept activity
start intents, and it can start activities directly.

Change-Id: I9dab1da6362bd0ab326673511fa09aa04e1665c3
Fix CPU spike in event server

If the client socket disconnects in a particular way, the event server can get
stuck in the inner while loop where it reads protobuf messages in. The existing
error check for a null protobuf would break that iteration of the loop, but did
not break out of the loop itself.

Changed 'continue' to 'break' as a temporary fix. It really should throw an
exception, but this is good enough for now since I'm planning to rewrite the
event server pretty soon anyway.

Change-Id: Ic4f5a32beff2688a38bb373a882f70a477c4a75b