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

Side by Side Diff: content/test/web_contents_observer_sanity_checker.h

Issue 1478643002: Refactor media out of WebContentsImpl to MediaWebContentsObserver. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix namespace for cast. Created 5 years 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CONTENT_TEST_WEB_CONTENTS_OBSERVER_SANITY_CHECKER_H_ 5 #ifndef CONTENT_TEST_WEB_CONTENTS_OBSERVER_SANITY_CHECKER_H_
6 #define CONTENT_TEST_WEB_CONTENTS_OBSERVER_SANITY_CHECKER_H_ 6 #define CONTENT_TEST_WEB_CONTENTS_OBSERVER_SANITY_CHECKER_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 10
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 bool was_ignored_by_handler) override; 74 bool was_ignored_by_handler) override;
75 void DidGetRedirectForResourceRequest( 75 void DidGetRedirectForResourceRequest(
76 RenderFrameHost* render_frame_host, 76 RenderFrameHost* render_frame_host,
77 const ResourceRedirectDetails& details) override; 77 const ResourceRedirectDetails& details) override;
78 void DidOpenRequestedURL(WebContents* new_contents, 78 void DidOpenRequestedURL(WebContents* new_contents,
79 RenderFrameHost* source_render_frame_host, 79 RenderFrameHost* source_render_frame_host,
80 const GURL& url, 80 const GURL& url,
81 const Referrer& referrer, 81 const Referrer& referrer,
82 WindowOpenDisposition disposition, 82 WindowOpenDisposition disposition,
83 ui::PageTransition transition) override; 83 ui::PageTransition transition) override;
84 void MediaStartedPlaying(const MediaPlayerId& id) override;
85 void MediaStoppedPlaying(const MediaPlayerId& id) override;
84 bool OnMessageReceived(const IPC::Message& message, 86 bool OnMessageReceived(const IPC::Message& message,
85 RenderFrameHost* render_frame_host) override; 87 RenderFrameHost* render_frame_host) override;
86 void WebContentsDestroyed() override; 88 void WebContentsDestroyed() override;
87 89
88 private: 90 private:
89 explicit WebContentsObserverSanityChecker(WebContents* web_contents); 91 explicit WebContentsObserverSanityChecker(WebContents* web_contents);
90 ~WebContentsObserverSanityChecker() override; 92 ~WebContentsObserverSanityChecker() override;
91 93
92 std::string Format(RenderFrameHost* render_frame_host); 94 std::string Format(RenderFrameHost* render_frame_host);
93 void AssertRenderFrameExists(RenderFrameHost* render_frame_host); 95 void AssertRenderFrameExists(RenderFrameHost* render_frame_host);
94 void AssertMainFrameExists(); 96 void AssertMainFrameExists();
95 97
96 bool NavigationIsOngoing(NavigationHandle* navigation_handle); 98 bool NavigationIsOngoing(NavigationHandle* navigation_handle);
97 99
98 std::set<std::pair<int, int>> current_hosts_; 100 std::set<std::pair<int, int>> current_hosts_;
99 std::set<std::pair<int, int>> live_routes_; 101 std::set<std::pair<int, int>> live_routes_;
100 std::set<std::pair<int, int>> deleted_routes_; 102 std::set<std::pair<int, int>> deleted_routes_;
101 103
102 std::set<NavigationHandle*> ongoing_navigations_; 104 std::set<NavigationHandle*> ongoing_navigations_;
105 std::vector<MediaPlayerId> active_media_players_;
103 106
104 bool web_contents_destroyed_; 107 bool web_contents_destroyed_;
105 108
106 DISALLOW_COPY_AND_ASSIGN(WebContentsObserverSanityChecker); 109 DISALLOW_COPY_AND_ASSIGN(WebContentsObserverSanityChecker);
107 }; 110 };
108 111
109 } // namespace content 112 } // namespace content
110 113
111 #endif // CONTENT_TEST_WEB_CONTENTS_OBSERVER_SANITY_CHECKER_H_ 114 #endif // CONTENT_TEST_WEB_CONTENTS_OBSERVER_SANITY_CHECKER_H_
OLDNEW
« no previous file with comments | « content/public/browser/web_contents_observer.h ('k') | content/test/web_contents_observer_sanity_checker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698