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

Side by Side Diff: chrome/browser/extensions/api/downloads_internal/downloads_internal_api.cc

Issue 23547011: Move c/b/extension/api/* into extensions namespace (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 7 years, 3 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 (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 "chrome/browser/extensions/api/downloads_internal/downloads_internal_ap i.h" 5 #include "chrome/browser/extensions/api/downloads_internal/downloads_internal_ap i.h"
6 6
7 #include "chrome/browser/extensions/api/downloads/downloads_api.h" 7 #include "chrome/browser/extensions/api/downloads/downloads_api.h"
8 #include "chrome/common/extensions/api/downloads.h" 8 #include "chrome/common/extensions/api/downloads.h"
9 #include "chrome/common/extensions/api/downloads_internal.h" 9 #include "chrome/common/extensions/api/downloads_internal.h"
10 10
11 namespace extensions {
12
11 DownloadsInternalDetermineFilenameFunction:: 13 DownloadsInternalDetermineFilenameFunction::
12 DownloadsInternalDetermineFilenameFunction() {} 14 DownloadsInternalDetermineFilenameFunction() {}
13 15
14 DownloadsInternalDetermineFilenameFunction:: 16 DownloadsInternalDetermineFilenameFunction::
15 ~DownloadsInternalDetermineFilenameFunction() {} 17 ~DownloadsInternalDetermineFilenameFunction() {}
16 18
17 typedef extensions::api::downloads_internal::DetermineFilename::Params 19 typedef extensions::api::downloads_internal::DetermineFilename::Params
18 DetermineFilenameParams; 20 DetermineFilenameParams;
19 21
20 bool DownloadsInternalDetermineFilenameFunction::RunImpl() { 22 bool DownloadsInternalDetermineFilenameFunction::RunImpl() {
21 scoped_ptr<DetermineFilenameParams> params( 23 scoped_ptr<DetermineFilenameParams> params(
22 DetermineFilenameParams::Create(*args_)); 24 DetermineFilenameParams::Create(*args_));
23 EXTENSION_FUNCTION_VALIDATE(params.get()); 25 EXTENSION_FUNCTION_VALIDATE(params.get());
24 base::FilePath::StringType filename; 26 base::FilePath::StringType filename;
25 EXTENSION_FUNCTION_VALIDATE(args_->GetString(1, &filename)); 27 EXTENSION_FUNCTION_VALIDATE(args_->GetString(1, &filename));
26 return ExtensionDownloadsEventRouter::DetermineFilename( 28 return ExtensionDownloadsEventRouter::DetermineFilename(
27 profile(), 29 profile(),
28 include_incognito(), 30 include_incognito(),
29 GetExtension()->id(), 31 GetExtension()->id(),
30 params->download_id, 32 params->download_id,
31 base::FilePath(filename), 33 base::FilePath(filename),
32 extensions::api::downloads::ParseFilenameConflictAction( 34 extensions::api::downloads::ParseFilenameConflictAction(
33 params->conflict_action), 35 params->conflict_action),
34 &error_); 36 &error_);
35 } 37 }
38
39 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698