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

Side by Side Diff: chrome/browser/extensions/app_notify_channel_setup.h

Issue 8375039: Create a content::UrlFetcher interface that lives in content/public/common and convert users to i... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: review comments Created 9 years, 2 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_EXTENSIONS_APP_NOTIFY_CHANNEL_SETUP_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_APP_NOTIFY_CHANNEL_SETUP_H_
6 #define CHROME_BROWSER_EXTENSIONS_APP_NOTIFY_CHANNEL_SETUP_H_ 6 #define CHROME_BROWSER_EXTENSIONS_APP_NOTIFY_CHANNEL_SETUP_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 26 matching lines...) Expand all
37 int callback_id, 37 int callback_id,
38 base::WeakPtr<Delegate> delegate); 38 base::WeakPtr<Delegate> delegate);
39 39
40 // This begins the process of fetching the channel id using the browser login 40 // This begins the process of fetching the channel id using the browser login
41 // credentials. If the user isn't logged in to chrome, this will first cause a 41 // credentials. If the user isn't logged in to chrome, this will first cause a
42 // prompt to appear asking the user to log in. 42 // prompt to appear asking the user to log in.
43 void Start(); 43 void Start();
44 44
45 protected: 45 protected:
46 // content::URLFetcherDelegate. 46 // content::URLFetcherDelegate.
47 virtual void OnURLFetchComplete(const URLFetcher* source) OVERRIDE; 47 virtual void OnURLFetchComplete(const content::URLFetcher* source) OVERRIDE;
48 48
49 private: 49 private:
50 friend class base::RefCountedThreadSafe<AppNotifyChannelSetup>; 50 friend class base::RefCountedThreadSafe<AppNotifyChannelSetup>;
51 51
52 virtual ~AppNotifyChannelSetup(); 52 virtual ~AppNotifyChannelSetup();
53 53
54 void ReportResult(const std::string& channel_id, const std::string& error); 54 void ReportResult(const std::string& channel_id, const std::string& error);
55 55
56 Profile* profile_; 56 Profile* profile_;
57 std::string client_id_; 57 std::string client_id_;
58 GURL requestor_url_; 58 GURL requestor_url_;
59 int return_route_id_; 59 int return_route_id_;
60 int callback_id_; 60 int callback_id_;
61 base::WeakPtr<Delegate> delegate_; 61 base::WeakPtr<Delegate> delegate_;
62 scoped_ptr<URLFetcher> url_fetcher_; 62 scoped_ptr<content::URLFetcher> url_fetcher_;
63 63
64 DISALLOW_COPY_AND_ASSIGN(AppNotifyChannelSetup); 64 DISALLOW_COPY_AND_ASSIGN(AppNotifyChannelSetup);
65 }; 65 };
66 66
67 #endif // CHROME_BROWSER_EXTENSIONS_APP_NOTIFY_CHANNEL_SETUP_H_ 67 #endif // CHROME_BROWSER_EXTENSIONS_APP_NOTIFY_CHANNEL_SETUP_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698