Surface synchronization: Fix BrowserPluginGuest surface invariants violations

This CL fixes a few surface invariants violations in BrowserPluginGuest that
were causing flaky tests.

1. We were using ScreenInfo from BrowserPluginGuest to the child renderer before
   we've grabbed a LocalSurfaceId from the parent. This results in surface
   invariants violations occasionally.

2. There is extension code that races with content code to resize the guest.
   This results in surface invariants violations. The solution is to ignore
   extension code requests and only resize from content. OOPIF-based
   BrowserPluginGuest already does this. Do it for the old code path too.

Bug: 672962, 814040, 791154
TBR: piman@chromium.org (for render_widget_host_view_guest.cc) I used to own that but it moved :(
Cq-Include-Trybots: master.tryserver.chromium.android:android_optional_gpu_tests_rel
Change-Id: Ib5783dee73ce525004f9e9b06c74a8d703e7157b
Reviewed-on: https://chromium-review.googlesource.com/932964
Commit-Queue: Fady Samuel <fsamuel@chromium.org>
Reviewed-by: Ken Buchanan <kenrb@chromium.org>
Reviewed-by: Saman Sami <samans@chromium.org>
Cr-Commit-Position: refs/heads/master@{#539718}
9 files changed