cc: Added inline to Tile::IsReadyToDraw
[chromium-blink-merge.git] / media / video / capture / video_capture_device.cc
blob5c1245613dd081e9e6bea051a44b8fc56bae02b5
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "media/video/capture/video_capture_device.h"
7 namespace media {
9 const std::string VideoCaptureDevice::Name::GetNameAndModel() const {
10 // On Linux, the device name already includes the model identifier.
11 #if !defined(OS_LINUX)
12 std::string model_id = GetModel();
13 if (!model_id.empty())
14 return device_name_ + " (" + model_id + ")";
15 #endif // if !defined(OS_LINUX)
16 return device_name_;
19 VideoCaptureDevice::Name*
20 VideoCaptureDevice::Names::FindById(const std::string& id) {
21 for (iterator it = begin(); it != end(); ++it) {
22 if (it->id() == id)
23 return &(*it);
25 return NULL;
28 } // namespace media