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

Side by Side Diff: chrome/browser/ui/intents/web_intent_picker_controller.h

Issue 10993064: Make using WebContentsUserData simpler. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 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) 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_UI_INTENTS_WEB_INTENT_PICKER_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_UI_INTENTS_WEB_INTENT_PICKER_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_INTENTS_WEB_INTENT_PICKER_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_INTENTS_WEB_INTENT_PICKER_CONTROLLER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 virtual void OnChooseAnotherService() OVERRIDE; 113 virtual void OnChooseAnotherService() OVERRIDE;
114 virtual void OnClosing() OVERRIDE; 114 virtual void OnClosing() OVERRIDE;
115 115
116 // extensions::WebstoreInstaller::Delegate implementation. 116 // extensions::WebstoreInstaller::Delegate implementation.
117 virtual void OnExtensionInstallSuccess(const std::string& id) OVERRIDE; 117 virtual void OnExtensionInstallSuccess(const std::string& id) OVERRIDE;
118 virtual void OnExtensionInstallFailure(const std::string& id, 118 virtual void OnExtensionInstallFailure(const std::string& id,
119 const std::string& error) OVERRIDE; 119 const std::string& error) OVERRIDE;
120 120
121 private: 121 private:
122 explicit WebIntentPickerController(content::WebContents* web_contents); 122 explicit WebIntentPickerController(content::WebContents* web_contents);
123 static int kUserDataKey;
124 friend class WebContentsUserData<WebIntentPickerController>; 123 friend class WebContentsUserData<WebIntentPickerController>;
125 124
126 friend class WebIntentPickerControllerTest; 125 friend class WebIntentPickerControllerTest;
127 friend class WebIntentPickerControllerBrowserTest; 126 friend class WebIntentPickerControllerBrowserTest;
128 friend class WebIntentPickerControllerIncognitoBrowserTest; 127 friend class WebIntentPickerControllerIncognitoBrowserTest;
129 friend class WebIntentsButtonDecorationTest; 128 friend class WebIntentsButtonDecorationTest;
130 129
131 // Forward declaraton of the internal implementation class. 130 // Forward declaraton of the internal implementation class.
132 class UMAReporter; 131 class UMAReporter;
133 132
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
329 // Bucket identifier for UMA reporting. Saved off in a field 328 // Bucket identifier for UMA reporting. Saved off in a field
330 // to avoid repeated calculation of the bucket across 329 // to avoid repeated calculation of the bucket across
331 // multiple UMA calls. Should be recalculated each time 330 // multiple UMA calls. Should be recalculated each time
332 // |intents_dispatcher_| is set. 331 // |intents_dispatcher_| is set.
333 web_intents::UMABucket uma_bucket_; 332 web_intents::UMABucket uma_bucket_;
334 333
335 DISALLOW_COPY_AND_ASSIGN(WebIntentPickerController); 334 DISALLOW_COPY_AND_ASSIGN(WebIntentPickerController);
336 }; 335 };
337 336
338 #endif // CHROME_BROWSER_UI_INTENTS_WEB_INTENT_PICKER_CONTROLLER_H_ 337 #endif // CHROME_BROWSER_UI_INTENTS_WEB_INTENT_PICKER_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698