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

Side by Side Diff: chrome/browser/extensions/api/downloads/downloads_api.cc

Issue 12087095: Sync csd.proto with server-side version. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: missing comma Created 7 years, 10 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/downloads_api.h" 5 #include "chrome/browser/extensions/api/downloads/downloads_api.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cctype> 8 #include <cctype>
9 #include <iterator> 9 #include <iterator>
10 #include <set> 10 #include <set>
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 87
88 // Parameter keys 88 // Parameter keys
89 const char kBytesReceivedKey[] = "bytesReceived"; 89 const char kBytesReceivedKey[] = "bytesReceived";
90 const char kDangerAcceptedKey[] = "dangerAccepted"; 90 const char kDangerAcceptedKey[] = "dangerAccepted";
91 const char kDangerContent[] = "content"; 91 const char kDangerContent[] = "content";
92 const char kDangerFile[] = "file"; 92 const char kDangerFile[] = "file";
93 const char kDangerKey[] = "danger"; 93 const char kDangerKey[] = "danger";
94 const char kDangerSafe[] = "safe"; 94 const char kDangerSafe[] = "safe";
95 const char kDangerUncommon[] = "uncommon"; 95 const char kDangerUncommon[] = "uncommon";
96 const char kDangerAccepted[] = "accepted"; 96 const char kDangerAccepted[] = "accepted";
97 const char kDangerHost[] = "host";
97 const char kDangerUrl[] = "url"; 98 const char kDangerUrl[] = "url";
98 const char kEndTimeKey[] = "endTime"; 99 const char kEndTimeKey[] = "endTime";
99 const char kEndedAfterKey[] = "endedAfter"; 100 const char kEndedAfterKey[] = "endedAfter";
100 const char kEndedBeforeKey[] = "endedBefore"; 101 const char kEndedBeforeKey[] = "endedBefore";
101 const char kErrorKey[] = "error"; 102 const char kErrorKey[] = "error";
102 const char kExistsKey[] = "exists"; 103 const char kExistsKey[] = "exists";
103 const char kFileSizeKey[] = "fileSize"; 104 const char kFileSizeKey[] = "fileSize";
104 const char kFilenameKey[] = "filename"; 105 const char kFilenameKey[] = "filename";
105 const char kFilenameRegexKey[] = "filenameRegex"; 106 const char kFilenameRegexKey[] = "filenameRegex";
106 const char kIdKey[] = "id"; 107 const char kIdKey[] = "id";
(...skipping 17 matching lines...) Expand all
124 // Note: Any change to the danger type strings, should be accompanied by a 125 // Note: Any change to the danger type strings, should be accompanied by a
125 // corresponding change to downloads.json. 126 // corresponding change to downloads.json.
126 const char* kDangerStrings[] = { 127 const char* kDangerStrings[] = {
127 kDangerSafe, 128 kDangerSafe,
128 kDangerFile, 129 kDangerFile,
129 kDangerUrl, 130 kDangerUrl,
130 kDangerContent, 131 kDangerContent,
131 kDangerSafe, 132 kDangerSafe,
132 kDangerUncommon, 133 kDangerUncommon,
133 kDangerAccepted, 134 kDangerAccepted,
135 kDangerHost,
134 }; 136 };
135 COMPILE_ASSERT(arraysize(kDangerStrings) == content::DOWNLOAD_DANGER_TYPE_MAX, 137 COMPILE_ASSERT(arraysize(kDangerStrings) == content::DOWNLOAD_DANGER_TYPE_MAX,
136 download_danger_type_enum_changed); 138 download_danger_type_enum_changed);
137 139
138 // Note: Any change to the state strings, should be accompanied by a 140 // Note: Any change to the state strings, should be accompanied by a
139 // corresponding change to downloads.json. 141 // corresponding change to downloads.json.
140 const char* kStateStrings[] = { 142 const char* kStateStrings[] = {
141 kStateInProgress, 143 kStateInProgress,
142 kStateComplete, 144 kStateComplete,
143 kStateInterrupted, 145 kStateInterrupted,
(...skipping 1000 matching lines...) Expand 10 before | Expand all | Expand 10 after
1144 if (profile_->HasOffTheRecordProfile() && 1146 if (profile_->HasOffTheRecordProfile() &&
1145 !profile_->IsOffTheRecord()) { 1147 !profile_->IsOffTheRecord()) {
1146 DispatchEventInternal( 1148 DispatchEventInternal(
1147 profile_->GetOffTheRecordProfile(), 1149 profile_->GetOffTheRecordProfile(),
1148 event_name, 1150 event_name,
1149 json_args, 1151 json_args,
1150 scoped_ptr<base::ListValue>(args->DeepCopy())); 1152 scoped_ptr<base::ListValue>(args->DeepCopy()));
1151 } 1153 }
1152 DispatchEventInternal(profile_, event_name, json_args, args.Pass()); 1154 DispatchEventInternal(profile_, event_name, json_args, args.Pass());
1153 } 1155 }
OLDNEW
« no previous file with comments | « chrome/browser/download/download_item_model.cc ('k') | chrome/browser/resources/downloads/downloads.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698