VisualBench: Use first succeeding EGL API

Fix initialization of the app window by
using the first EGL context that succeeds, not the last one.

Fixes the window creation in some cases on devices that support
OpenGL and OpenGL ES.

Also check EGL call results.

BUG=skia:4733
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1582313002

Review URL: https://codereview.chromium.org/1582313002
1 file changed