Abort surface composition if hw surface is invalid

If an invalid display device is detected during surface composition
(e.g., a simulated secondary display is removed), abort the
composition.

Change-Id: Ia6afb2e287882d8ae0614eb25463d3f85b687adf
gl_code.cpp: Remove a DOS style newline

Change-Id: Id3edd6e511371fa8b0afef2e90baed4662ed76c4
Signed-off-by: Bernhard Rosenkränzer <Bernhard.Rosenkranzer@linaro.org>
Overlay support for legacy camera libs

Move http://review.cyanogenmod.com/#/c/13285/ to proper place for jellybean.

1. Rename OverlayHtc to Overlay in file names
2. Use BOARD_USES_LEGACY_OVERLAY to enable

Signed-off-by: Evan McClain <aeroevan@gmail.com>
Change-Id: Ib6afd1b610b1d3e263fcaa38585e7a1116baaf58