Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(21)

Side by Side Diff: components/contextual_search/renderer/overlay_js_render_frame_observer.h

Issue 2079943002: Change RenderFrame to use InterfaceRegistry et al. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@a2
Patch Set: . Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef COMPONENTS_CONTEXTUAL_SEARCH_RENDERER_OVERLAY_JS_RENDER_FRAME_OBSERVER_H _ 5 #ifndef COMPONENTS_CONTEXTUAL_SEARCH_RENDERER_OVERLAY_JS_RENDER_FRAME_OBSERVER_H _
6 #define COMPONENTS_CONTEXTUAL_SEARCH_RENDERER_OVERLAY_JS_RENDER_FRAME_OBSERVER_H _ 6 #define COMPONENTS_CONTEXTUAL_SEARCH_RENDERER_OVERLAY_JS_RENDER_FRAME_OBSERVER_H _
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "components/contextual_search/common/overlay_page_notifier_service.mojo m.h" 10 #include "components/contextual_search/common/overlay_page_notifier_service.mojo m.h"
(...skipping 18 matching lines...) Expand all
29 void DidClearWindowObject() override; 29 void DidClearWindowObject() override;
30 void DidFinishLoad() override; 30 void DidFinishLoad() override;
31 31
32 // Flag the current page as a contextual search overlay. 32 // Flag the current page as a contextual search overlay.
33 void SetIsContextualSearchOverlay(); 33 void SetIsContextualSearchOverlay();
34 34
35 private: 35 private:
36 // RenderFrameObserver implementation. 36 // RenderFrameObserver implementation.
37 void OnDestruct() override; 37 void OnDestruct() override;
38 38
39 // Add the mojo service to a RenderFrame's service registry. 39 // Add the mojo interface to a RenderFrame's shell::InterfaceRegistry.
40 void RegisterMojoService(); 40 void RegisterMojoInterface();
41 void CreateOverlayPageNotifierService( 41 void CreateOverlayPageNotifierService(
42 mojo::InterfaceRequest<mojom::OverlayPageNotifierService> request); 42 mojo::InterfaceRequest<mojom::OverlayPageNotifierService> request);
43 43
44 // Track if the current page is presented in the contextual search overlay. 44 // Track if the current page is presented in the contextual search overlay.
45 bool is_contextual_search_overlay_; 45 bool is_contextual_search_overlay_;
46 46
47 base::WeakPtrFactory<OverlayJsRenderFrameObserver> weak_factory_; 47 base::WeakPtrFactory<OverlayJsRenderFrameObserver> weak_factory_;
48 48
49 DISALLOW_COPY_AND_ASSIGN(OverlayJsRenderFrameObserver); 49 DISALLOW_COPY_AND_ASSIGN(OverlayJsRenderFrameObserver);
50 }; 50 };
51 51
52 } // namespace contextual_search 52 } // namespace contextual_search
53 53
54 #endif // COMPONENTS_CONTEXTUAL_SEARCH_RENDERER_OVERLAY_JS_RENDER_FRAME_OBSERVE R_H_ 54 #endif // COMPONENTS_CONTEXTUAL_SEARCH_RENDERER_OVERLAY_JS_RENDER_FRAME_OBSERVE R_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698