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

Side by Side Diff: chrome/browser/media_galleries/fileapi/supported_audio_video_checker.cc

Issue 145303002: Convert Media Galleries to use base::File (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 11 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 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_galleries/fileapi/supported_audio_video_checker.h " 5 #include "chrome/browser/media_galleries/fileapi/supported_audio_video_checker.h "
6 6
7 #include <set> 7 #include <set>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 80
81 SupportedAudioVideoChecker::SupportedAudioVideoChecker( 81 SupportedAudioVideoChecker::SupportedAudioVideoChecker(
82 const base::FilePath& path) 82 const base::FilePath& path)
83 : path_(path), 83 : path_(path),
84 weak_factory_(this) { 84 weak_factory_(this) {
85 } 85 }
86 86
87 void SupportedAudioVideoChecker::OnFileOpen(const base::PlatformFile& file) { 87 void SupportedAudioVideoChecker::OnFileOpen(const base::PlatformFile& file) {
88 DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::IO)); 88 DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::IO));
89 if (file == base::kInvalidPlatformFileValue) { 89 if (file == base::kInvalidPlatformFileValue) {
90 callback_.Run(base::PLATFORM_FILE_ERROR_SECURITY); 90 callback_.Run(base::File::FILE_ERROR_SECURITY);
91 return; 91 return;
92 } 92 }
93 93
94 safe_checker_ = new SafeAudioVideoChecker(file, callback_); 94 safe_checker_ = new SafeAudioVideoChecker(file, callback_);
95 safe_checker_->Start(); 95 safe_checker_->Start();
96 } 96 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698