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

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

Issue 213703004: Ensure that WebRTC AEC recording checkbox is not set if cancelling file dialog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Code review fixes + rebase. Created 6 years, 8 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 | Annotate | Revision Log
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 #include "content/browser/media/webrtc_internals.h" 5 #include "content/browser/media/webrtc_internals.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "content/browser/media/webrtc_internals_ui_observer.h" 8 #include "content/browser/media/webrtc_internals_ui_observer.h"
9 #include "content/public/browser/browser_thread.h" 9 #include "content/public/browser/browser_thread.h"
10 #include "content/public/browser/notification_service.h" 10 #include "content/public/browser/notification_service.h"
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after
282 282
283 void WebRTCInternals::FileSelected(const base::FilePath& path, 283 void WebRTCInternals::FileSelected(const base::FilePath& path,
284 int /* unused_index */, 284 int /* unused_index */,
285 void* /*unused_params */) { 285 void* /*unused_params */) {
286 #if defined(ENABLE_WEBRTC) 286 #if defined(ENABLE_WEBRTC)
287 aec_dump_file_path_ = path; 287 aec_dump_file_path_ = path;
288 EnableAecDumpOnAllRenderProcessHosts(); 288 EnableAecDumpOnAllRenderProcessHosts();
289 #endif 289 #endif
290 } 290 }
291 291
292 void WebRTCInternals::FileSelectionCanceled(void* params) {
293 #if defined(ENABLE_WEBRTC)
294 SendUpdate("aecRecordingFileSelectionCancelled", NULL);
295 #endif
296 }
297
292 void WebRTCInternals::OnRendererExit(int render_process_id) { 298 void WebRTCInternals::OnRendererExit(int render_process_id) {
293 // Iterates from the end of the list to remove the PeerConnections created 299 // Iterates from the end of the list to remove the PeerConnections created
294 // by the exitting renderer. 300 // by the exitting renderer.
295 for (int i = peer_connection_data_.GetSize() - 1; i >= 0; --i) { 301 for (int i = peer_connection_data_.GetSize() - 1; i >= 0; --i) {
296 base::DictionaryValue* record = NULL; 302 base::DictionaryValue* record = NULL;
297 peer_connection_data_.GetDictionary(i, &record); 303 peer_connection_data_.GetDictionary(i, &record);
298 304
299 int this_rid = 0; 305 int this_rid = 0;
300 record->GetInteger("rid", &this_rid); 306 record->GetInteger("rid", &this_rid);
301 307
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 aec_dump_enabled_ = true; 348 aec_dump_enabled_ = true;
343 for (RenderProcessHost::iterator i( 349 for (RenderProcessHost::iterator i(
344 content::RenderProcessHost::AllHostsIterator()); 350 content::RenderProcessHost::AllHostsIterator());
345 !i.IsAtEnd(); i.Advance()) { 351 !i.IsAtEnd(); i.Advance()) {
346 i.GetCurrentValue()->EnableAecDump(aec_dump_file_path_); 352 i.GetCurrentValue()->EnableAecDump(aec_dump_file_path_);
347 } 353 }
348 } 354 }
349 #endif 355 #endif
350 356
351 } // namespace content 357 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/media/webrtc_internals.h ('k') | content/browser/media/webrtc_internals_message_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698