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

Side by Side Diff: content/browser/media/webrtc_internals.h

Issue 575283004: Change WebRTCInternals::GetInstance() to use a leaky LazyInstance. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Change WebRTCInternals::GetInstance to use LazyInstance. Created 6 years, 3 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
« no previous file with comments | « no previous file | content/browser/media/webrtc_internals.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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_BROWSER_MEDIA_WEBRTC_INTERNALS_H_ 5 #ifndef CONTENT_BROWSER_MEDIA_WEBRTC_INTERNALS_H_
6 #define CONTENT_BROWSER_MEDIA_WEBRTC_INTERNALS_H_ 6 #define CONTENT_BROWSER_MEDIA_WEBRTC_INTERNALS_H_
7 7
8 #include "base/gtest_prod_util.h" 8 #include "base/gtest_prod_util.h"
9 #include "base/lazy_instance.h"
9 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
10 #include "base/memory/singleton.h"
11 #include "base/observer_list.h" 11 #include "base/observer_list.h"
12 #include "base/process/process.h" 12 #include "base/process/process.h"
13 #include "base/values.h" 13 #include "base/values.h"
14 #include "content/common/content_export.h" 14 #include "content/common/content_export.h"
15 #include "content/public/browser/notification_observer.h" 15 #include "content/public/browser/notification_observer.h"
16 #include "content/public/browser/notification_registrar.h" 16 #include "content/public/browser/notification_registrar.h"
17 #include "ui/shell_dialogs/select_file_dialog.h" 17 #include "ui/shell_dialogs/select_file_dialog.h"
18 18
19 namespace content { 19 namespace content {
20 20
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 return aec_dump_enabled_; 95 return aec_dump_enabled_;
96 } 96 }
97 97
98 base::FilePath aec_dump_file_path() { 98 base::FilePath aec_dump_file_path() {
99 return aec_dump_file_path_; 99 return aec_dump_file_path_;
100 } 100 }
101 101
102 void ResetForTesting(); 102 void ResetForTesting();
103 103
104 private: 104 private:
105 friend struct DefaultSingletonTraits<WebRTCInternals>; 105 friend struct base::DefaultLazyInstanceTraits<WebRTCInternals>;
106 FRIEND_TEST_ALL_PREFIXES(WebRtcAecDumpBrowserTest, CallWithAecDump); 106 FRIEND_TEST_ALL_PREFIXES(WebRtcAecDumpBrowserTest, CallWithAecDump);
107 FRIEND_TEST_ALL_PREFIXES(WebRtcAecDumpBrowserTest, 107 FRIEND_TEST_ALL_PREFIXES(WebRtcAecDumpBrowserTest,
108 CallWithAecDumpEnabledThenDisabled); 108 CallWithAecDumpEnabledThenDisabled);
109 FRIEND_TEST_ALL_PREFIXES(WebRtcAecDumpBrowserTest, TwoCallsWithAecDump); 109 FRIEND_TEST_ALL_PREFIXES(WebRtcAecDumpBrowserTest, TwoCallsWithAecDump);
110 FRIEND_TEST_ALL_PREFIXES(WebRTCInternalsTest, 110 FRIEND_TEST_ALL_PREFIXES(WebRTCInternalsTest,
111 AecRecordingFileSelectionCanceled); 111 AecRecordingFileSelectionCanceled);
112 112
113 WebRTCInternals(); 113 WebRTCInternals();
114 virtual ~WebRTCInternals(); 114 virtual ~WebRTCInternals();
115 115
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 177
178 // While |peer_connection_data_| is non-empty, hold an instance of 178 // While |peer_connection_data_| is non-empty, hold an instance of
179 // PowerSaveBlocker. This prevents the application from being suspended while 179 // PowerSaveBlocker. This prevents the application from being suspended while
180 // remoting. 180 // remoting.
181 scoped_ptr<PowerSaveBlocker> power_save_blocker_; 181 scoped_ptr<PowerSaveBlocker> power_save_blocker_;
182 }; 182 };
183 183
184 } // namespace content 184 } // namespace content
185 185
186 #endif // CONTENT_BROWSER_MEDIA_WEBRTC_INTERNALS_H_ 186 #endif // CONTENT_BROWSER_MEDIA_WEBRTC_INTERNALS_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/media/webrtc_internals.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698