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

Side by Side Diff: chrome/browser/chromeos/gdata/gdata_operations.cc

Issue 10332260: gdata: Fix URLs used for fetching documents in a particular directory (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 7 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/chromeos/gdata/gdata_operations.h" 5 #include "chrome/browser/chromeos/gdata/gdata_operations.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/json/json_reader.h" 8 #include "base/json/json_reader.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/string_number_conversions.h" 10 #include "base/string_number_conversions.h"
(...skipping 23 matching lines...) Expand all
34 // Template for optional OAuth2 authorization HTTP header. 34 // Template for optional OAuth2 authorization HTTP header.
35 const char kAuthorizationHeaderFormat[] = "Authorization: Bearer %s"; 35 const char kAuthorizationHeaderFormat[] = "Authorization: Bearer %s";
36 // Template for GData API version HTTP header. 36 // Template for GData API version HTTP header.
37 const char kGDataVersionHeader[] = "GData-Version: 3.0"; 37 const char kGDataVersionHeader[] = "GData-Version: 3.0";
38 38
39 // etag matching header. 39 // etag matching header.
40 const char kIfMatchAllHeader[] = "If-Match: *"; 40 const char kIfMatchAllHeader[] = "If-Match: *";
41 const char kIfMatchHeaderFormat[] = "If-Match: %s"; 41 const char kIfMatchHeaderFormat[] = "If-Match: %s";
42 42
43 // URL requesting documents list that belong to the authenticated user only 43 // URL requesting documents list that belong to the authenticated user only
44 // (handled with '/mine' part). 44 // (handled with '/-/mine' part).
45 const char kGetDocumentListURLForAllDocuments[] = 45 const char kGetDocumentListURLForAllDocuments[] =
46 "https://docs.google.com/feeds/default/private/full/-/mine"; 46 "https://docs.google.com/feeds/default/private/full/-/mine";
47 // URL requesting documents list in a particular directory specified by "%s" 47 // URL requesting documents list in a particular directory specified by "%s"
48 // that belong to the authenticated user only (handled with '/mine' part). 48 // that belong to the authenticated user only (handled with '/-/mine' part).
49 const char kGetDocumentListURLForDirectoryFormat[] = 49 const char kGetDocumentListURLForDirectoryFormat[] =
50 "https://docs.google.com/feeds/default/private/full/%s/contents/mine"; 50 "https://docs.google.com/feeds/default/private/full/%s/contents/-/mine";
51 51
52 // URL requesting documents list of changes to documents collections. 52 // URL requesting documents list of changes to documents collections.
53 const char kGetChangesListURL[] = 53 const char kGetChangesListURL[] =
54 "https://docs.google.com/feeds/default/private/changes"; 54 "https://docs.google.com/feeds/default/private/changes";
55 55
56 // Root document list url. 56 // Root document list url.
57 const char kDocumentListRootURL[] = 57 const char kDocumentListRootURL[] =
58 "https://docs.google.com/feeds/default/private/full"; 58 "https://docs.google.com/feeds/default/private/full";
59 59
60 // Metadata feed with things like user quota. 60 // Metadata feed with things like user quota.
(...skipping 1009 matching lines...) Expand 10 before | Expand all | Expand 10 after
1070 return true; 1070 return true;
1071 } 1071 }
1072 1072
1073 void ResumeUploadOperation::OnURLFetchUploadProgress( 1073 void ResumeUploadOperation::OnURLFetchUploadProgress(
1074 const net::URLFetcher* source, int64 current, int64 total) { 1074 const net::URLFetcher* source, int64 current, int64 total) {
1075 // Adjust the progress values according to the range currently uploaded. 1075 // Adjust the progress values according to the range currently uploaded.
1076 NotifyProgress(params_.start_range + current, params_.content_length); 1076 NotifyProgress(params_.start_range + current, params_.content_length);
1077 } 1077 }
1078 1078
1079 } // namespace gdata 1079 } // namespace gdata
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698