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

Side by Side Diff: content/browser/renderer_host/media/video_capture_manager.h

Issue 2086603002: video_capture_manager: filter out unexpected app state changes on Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address comments Created 4 years, 5 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/renderer_host/media/video_capture_manager.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) 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 // VideoCaptureManager is used to open/close, start/stop, enumerate available 5 // VideoCaptureManager is used to open/close, start/stop, enumerate available
6 // video capture devices, and manage VideoCaptureController's. 6 // video capture devices, and manage VideoCaptureController's.
7 // All functions are expected to be called from Browser::IO thread. Some helper 7 // All functions are expected to be called from Browser::IO thread. Some helper
8 // functions (*OnDeviceThread) will dispatch operations to the device thread. 8 // functions (*OnDeviceThread) will dispatch operations to the device thread.
9 // VideoCaptureManager will open OS dependent instances of VideoCaptureDevice. 9 // VideoCaptureManager will open OS dependent instances of VideoCaptureDevice.
10 // A device can only be opened once. 10 // A device can only be opened once.
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 // use them. This variable is only checked and set on the IO thread. 279 // use them. This variable is only checked and set on the IO thread.
280 bool capture_device_api_initialized_ = false; 280 bool capture_device_api_initialized_ = false;
281 #endif 281 #endif
282 282
283 #if defined(OS_ANDROID) 283 #if defined(OS_ANDROID)
284 void ReleaseDevices(); 284 void ReleaseDevices();
285 void ResumeDevices(); 285 void ResumeDevices();
286 286
287 std::unique_ptr<base::android::ApplicationStatusListener> 287 std::unique_ptr<base::android::ApplicationStatusListener>
288 app_status_listener_; 288 app_status_listener_;
289 bool application_state_has_running_activities_;
289 #endif 290 #endif
290 291
291 // The message loop of media stream device thread, where VCD's live. 292 // The message loop of media stream device thread, where VCD's live.
292 scoped_refptr<base::SingleThreadTaskRunner> device_task_runner_; 293 scoped_refptr<base::SingleThreadTaskRunner> device_task_runner_;
293 294
294 // Only accessed on Browser::IO thread. 295 // Only accessed on Browser::IO thread.
295 MediaStreamProviderListener* listener_; 296 MediaStreamProviderListener* listener_;
296 media::VideoCaptureSessionId new_capture_session_id_; 297 media::VideoCaptureSessionId new_capture_session_id_;
297 298
298 // An entry is kept in this map for every session that has been created via 299 // An entry is kept in this map for every session that has been created via
(...skipping 29 matching lines...) Expand all
328 // Map used by DesktopCapture. 329 // Map used by DesktopCapture.
329 std::map<media::VideoCaptureSessionId, gfx::NativeViewId> 330 std::map<media::VideoCaptureSessionId, gfx::NativeViewId>
330 notification_window_ids_; 331 notification_window_ids_;
331 332
332 DISALLOW_COPY_AND_ASSIGN(VideoCaptureManager); 333 DISALLOW_COPY_AND_ASSIGN(VideoCaptureManager);
333 }; 334 };
334 335
335 } // namespace content 336 } // namespace content
336 337
337 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_MANAGER_H_ 338 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_VIDEO_CAPTURE_MANAGER_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/renderer_host/media/video_capture_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698