| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 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 | 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 "chrome/browser/media/native_desktop_media_list.h" | 5 #include "chrome/browser/media/native_desktop_media_list.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <sstream> | 9 #include <sstream> |
| 10 | 10 |
| 11 #include "base/hash.h" | 11 #include "base/hash.h" |
| 12 #include "base/logging.h" | 12 #include "base/logging.h" |
| 13 #include "base/strings/utf_string_conversions.h" | 13 #include "base/strings/utf_string_conversions.h" |
| 14 #include "base/threading/sequenced_worker_pool.h" | 14 #include "base/threading/sequenced_worker_pool.h" |
| 15 #include "chrome/browser/media/desktop_media_list_observer.h" | 15 #include "chrome/browser/media/desktop_media_list_observer.h" |
| 16 #include "chrome/grit/generated_resources.h" |
| 16 #include "content/public/browser/browser_thread.h" | 17 #include "content/public/browser/browser_thread.h" |
| 17 #include "grit/generated_resources.h" | |
| 18 #include "media/base/video_util.h" | 18 #include "media/base/video_util.h" |
| 19 #include "third_party/libyuv/include/libyuv/scale_argb.h" | 19 #include "third_party/libyuv/include/libyuv/scale_argb.h" |
| 20 #include "third_party/skia/include/core/SkBitmap.h" | 20 #include "third_party/skia/include/core/SkBitmap.h" |
| 21 #include "third_party/webrtc/modules/desktop_capture/desktop_frame.h" | 21 #include "third_party/webrtc/modules/desktop_capture/desktop_frame.h" |
| 22 #include "third_party/webrtc/modules/desktop_capture/screen_capturer.h" | 22 #include "third_party/webrtc/modules/desktop_capture/screen_capturer.h" |
| 23 #include "third_party/webrtc/modules/desktop_capture/window_capturer.h" | 23 #include "third_party/webrtc/modules/desktop_capture/window_capturer.h" |
| 24 #include "ui/base/l10n/l10n_util.h" | 24 #include "ui/base/l10n/l10n_util.h" |
| 25 #include "ui/gfx/skia_util.h" | 25 #include "ui/gfx/skia_util.h" |
| 26 | 26 |
| 27 using content::BrowserThread; | 27 using content::BrowserThread; |
| (...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 361 observer_->OnSourceThumbnailChanged(index); | 361 observer_->OnSourceThumbnailChanged(index); |
| 362 } | 362 } |
| 363 | 363 |
| 364 void NativeDesktopMediaList::OnRefreshFinished() { | 364 void NativeDesktopMediaList::OnRefreshFinished() { |
| 365 BrowserThread::PostDelayedTask( | 365 BrowserThread::PostDelayedTask( |
| 366 BrowserThread::UI, FROM_HERE, | 366 BrowserThread::UI, FROM_HERE, |
| 367 base::Bind(&NativeDesktopMediaList::Refresh, | 367 base::Bind(&NativeDesktopMediaList::Refresh, |
| 368 weak_factory_.GetWeakPtr()), | 368 weak_factory_.GetWeakPtr()), |
| 369 update_period_); | 369 update_period_); |
| 370 } | 370 } |
| OLD | NEW |