Implement raster context loss methods

Notable changes in this CL:

- mark all RasterDecoderImpl class final (maybe compiler can
  devirtualize)

- copy over context loss related methods from GLES2DecoderImpl to
  RasterDecoderImpl

- port over GLES2Decoder context loss unit tests to RasterDecoder

Bug: 789238
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Change-Id: I919163ce459603109b12ee864561debb136ff594
Reviewed-on: https://chromium-review.googlesource.com/1025961
Commit-Queue: Jonathan Backer <[email protected]>
Reviewed-by: Peng Huang <[email protected]>
Cr-Commit-Position: refs/heads/master@{#553538}
diff --git a/gpu/BUILD.gn b/gpu/BUILD.gn
index 8d39107..f786ad8a 100644
--- a/gpu/BUILD.gn
+++ b/gpu/BUILD.gn
@@ -362,6 +362,7 @@
     "command_buffer/service/raster_decoder_unittest_1.cc",
     "command_buffer/service/raster_decoder_unittest_base.cc",
     "command_buffer/service/raster_decoder_unittest_base.h",
+    "command_buffer/service/raster_decoder_unittest_context_lost.cc",
     "command_buffer/service/renderbuffer_manager_unittest.cc",
     "command_buffer/service/scheduler_unittest.cc",
     "command_buffer/service/service_discardable_manager_unittest.cc",