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

Side by Side Diff: chrome/browser/chromeos/gdata/gdata_uploader.h

Issue 10836069: Revert 149576 - gdata: Make WeakPtrFactory the last parameter (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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 #ifndef CHROME_BROWSER_CHROMEOS_GDATA_GDATA_UPLOADER_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_GDATA_GDATA_UPLOADER_H_
6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_UPLOADER_H_ 6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_UPLOADER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 // Pointers to DocumentsServiceInterface object owned by GDataSystemService. 127 // Pointers to DocumentsServiceInterface object owned by GDataSystemService.
128 // The lifetime of this object is guaranteed to exceed that of the 128 // The lifetime of this object is guaranteed to exceed that of the
129 // GDataUploader instance. 129 // GDataUploader instance.
130 DocumentsServiceInterface* documents_service_; 130 DocumentsServiceInterface* documents_service_;
131 131
132 int next_upload_id_; // id counter. 132 int next_upload_id_; // id counter.
133 133
134 typedef std::map<int, UploadFileInfo*> UploadFileInfoMap; 134 typedef std::map<int, UploadFileInfo*> UploadFileInfoMap;
135 UploadFileInfoMap pending_uploads_; 135 UploadFileInfoMap pending_uploads_;
136 136
137 // Note: This should remain the last member so it'll be destroyed and 137 // Factory for various callbacks.
138 // invalidate its weak pointers before any other members are destroyed. 138 base::WeakPtrFactory<GDataUploader> uploader_factory_;
139 base::WeakPtrFactory<GDataUploader> weak_ptr_factory_;
140 139
141 DISALLOW_COPY_AND_ASSIGN(GDataUploader); 140 DISALLOW_COPY_AND_ASSIGN(GDataUploader);
142 }; 141 };
143 142
144 } // namespace gdata 143 } // namespace gdata
145 144
146 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_UPLOADER_H_ 145 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_UPLOADER_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/gdata/gdata_sync_client.h ('k') | chrome/browser/chromeos/gdata/gdata_uploader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698