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

Side by Side Diff: content/browser/renderer_host/media/media_stream_manager.cc

Issue 248113003: Fix for closing the desktop sharing notification bar when the shared window is closed (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 7 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/renderer_host/media/media_stream_manager.h" 5 #include "content/browser/renderer_host/media/media_stream_manager.h"
6 6
7 #include <list> 7 #include <list>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 1602 matching lines...) Expand 10 before | Expand all | Expand 10 after
1613 PostRequestToUI(*it, request); 1613 PostRequestToUI(*it, request);
1614 } 1614 }
1615 break; 1615 break;
1616 } 1616 }
1617 } 1617 }
1618 label_list.clear(); 1618 label_list.clear();
1619 --active_enumeration_ref_count_[stream_type]; 1619 --active_enumeration_ref_count_[stream_type];
1620 DCHECK_GE(active_enumeration_ref_count_[stream_type], 0); 1620 DCHECK_GE(active_enumeration_ref_count_[stream_type], 0);
1621 } 1621 }
1622 1622
1623 void MediaStreamManager::Aborted(MediaStreamType stream_type,
1624 int capture_session_id) {
1625 DCHECK_CURRENTLY_ON(BrowserThread::IO);
1626 DVLOG(1) << "Aborted({stream_type = " << stream_type << "} "
1627 << "{capture_session_id = " << capture_session_id << "})";
1628 StopDevice(stream_type, capture_session_id);
1629 }
1630
1623 // static 1631 // static
1624 void MediaStreamManager::SendMessageToNativeLog(const std::string& message) { 1632 void MediaStreamManager::SendMessageToNativeLog(const std::string& message) {
1625 BrowserThread::PostTask( 1633 BrowserThread::PostTask(
1626 BrowserThread::UI, FROM_HERE, 1634 BrowserThread::UI, FROM_HERE,
1627 base::Bind(DoAddLogMessage, message)); 1635 base::Bind(DoAddLogMessage, message));
1628 } 1636 }
1629 1637
1630 void MediaStreamManager::OnSuspend() { 1638 void MediaStreamManager::OnSuspend() {
1631 SendMessageToNativeLog("Power state suspended."); 1639 SendMessageToNativeLog("Power state suspended.");
1632 } 1640 }
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
1930 if (it->device.type == MEDIA_DESKTOP_VIDEO_CAPTURE) { 1938 if (it->device.type == MEDIA_DESKTOP_VIDEO_CAPTURE) {
1931 video_capture_manager_->SetDesktopCaptureWindowId(it->session_id, 1939 video_capture_manager_->SetDesktopCaptureWindowId(it->session_id,
1932 window_id); 1940 window_id);
1933 break; 1941 break;
1934 } 1942 }
1935 } 1943 }
1936 } 1944 }
1937 } 1945 }
1938 1946
1939 } // namespace content 1947 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698