EGL_OPENGL_ES3_BIT_KHR is set as ES 3 context is requested.

OpenGL ES have 3 configuration: 1(EGL10.EGL_RENDERABLE_TYPE),
2(EGL_OPENGL_ES2_BIT), 3(EGL_OPENGL_ES3_BIT_KHR). The driver
should be get the according configuration parameter.
Now 1 is set to driver when Configuration 3 is set from user.
Specification EGL_OPENGL_ES3_BIT_KHR is set to driver when a OpenGL
ES 3 context is requested in setEGLContextClientVersion().

Change-Id: I980d9d8dbe5754295f8329fcf9378962d669fa89
Signed-off-by: Jin Zhebin <zhebinx.jin@intel.com>
Signed-off-by: bdeng3X <bingx.deng@intel.com>
Fix the case where essential root activity vanishes from a task stack.

The following case creates a task stack which doesn't contain root
activity whose frontOfTask property is true.

[Precondition of a task stack]
  Top activity C    <== Focused
  Parent activity B
  Root activity A   <== Its frontOfTask property holds true.

[Procedure]
  1. Finish the B activity from C.
  2. Finish the A activity immediately after step 1.

[Resulted stack]
  Top activity C <== Focused, but frontOfTask holds false.

This patch can avoid the above case.

Change-Id: Icc456b010f67a79a655212007afb169f99797d7b