Move WidgetMsg_WasShown/WidgetMsg_WasHidden to blink's Widget mojom

This CL converts WidgetMsg_WasShown/WidgetMsg_WasHidden IPCs to
blink's Widget mojom and moves some implementation including
is_hidden into WidgetBase, and moves
ContentToVisibleTimeReporter class to blink.

Bug: 1102446
Change-Id: I40bf1444627fdac5a96becef0907f5662a6a45e4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2377630
Commit-Queue: Miyoung Shin <[email protected]>
Reviewed-by: Kinuko Yasuda <[email protected]>
Reviewed-by: Dave Tapuska <[email protected]>
Cr-Commit-Position: refs/heads/master@{#807798}
diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h
index c3d11c6b..c09a38f 100644
--- a/content/renderer/render_frame_impl.h
+++ b/content/renderer/render_frame_impl.h
@@ -306,10 +306,6 @@
   // Virtual for web tests to inject their own behaviour into the WebLocalFrame.
   virtual void Initialize(blink::WebFrame* parent);
 
-  // Notifications from RenderWidget.
-  void WasHidden();
-  void WasShown();
-
   // Start/Stop loading notifications.
   // TODO(nasko): Those are page-level methods at this time and come from
   // WebViewClient. We should move them to be WebLocalFrameClient calls and put
@@ -770,6 +766,8 @@
       const std::string& output_device_id) override;
   void DidMeaningfulLayout(blink::WebMeaningfulLayout layout_type) override;
   void DidCommitAndDrawCompositorFrame() override;
+  void WasHidden() override;
+  void WasShown() override;
 
   // Binds to the fullscreen service in the browser.
   void BindFullscreen(