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

Side by Side Diff: chrome/browser/autofill/autocheckout_manager.h

Issue 12091086: [Autofill] Add UMA timing metrics for requestAutocomplete dialog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase harder 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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_AUTOFILL_AUTOCHECKOUT_MANAGER_H_ 5 #ifndef CHROME_BROWSER_AUTOFILL_AUTOCHECKOUT_MANAGER_H_
6 #define CHROME_BROWSER_AUTOFILL_AUTOCHECKOUT_MANAGER_H_ 6 #define CHROME_BROWSER_AUTOFILL_AUTOCHECKOUT_MANAGER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 #include "base/memory/weak_ptr.h" 11 #include "base/memory/weak_ptr.h"
12 #include "base/string16.h" 12 #include "base/string16.h"
13 #include "chrome/browser/autofill/autocheckout_page_meta_data.h" 13 #include "chrome/browser/autofill/autocheckout_page_meta_data.h"
14 #include "ui/gfx/native_widget_types.h" 14 #include "ui/gfx/native_widget_types.h"
15 15
16 class AutofillField; 16 class AutofillField;
17 class AutofillManager; 17 class AutofillManager;
18 class AutofillProfile; 18 class AutofillProfile;
19 class CreditCard; 19 class CreditCard;
20 class FormStructure; 20 class FormStructure;
21 class GURL; 21 class GURL;
22 22
23 struct FormData; 23 struct FormData;
24 struct FormFieldData; 24 struct FormFieldData;
25 25
26 namespace autofill {
27 struct WebElementDescriptor;
28 }
29
30 namespace content { 26 namespace content {
31 struct SSLStatus; 27 struct SSLStatus;
32 } 28 }
33 29
34 namespace gfx { 30 namespace gfx {
35 class RectF; 31 class RectF;
36 } 32 }
37 33
34 namespace autofill {
35
38 class AutocheckoutManager { 36 class AutocheckoutManager {
39 public: 37 public:
40 explicit AutocheckoutManager(AutofillManager* autofill_manager); 38 explicit AutocheckoutManager(AutofillManager* autofill_manager);
41 virtual ~AutocheckoutManager(); 39 virtual ~AutocheckoutManager();
42 40
43 // Fill all the forms seen by the Autofill manager with the information 41 // Fill all the forms seen by the Autofill manager with the information
44 // gathered from the requestAutocomplete dialog. 42 // gathered from the requestAutocomplete dialog.
45 void FillForms(); 43 void FillForms();
46 44
47 // Sets |page_meta_data_| with the meta data for the current page. 45 // Sets |page_meta_data_| with the meta data for the current page.
48 void OnLoadedPageMetaData( 46 void OnLoadedPageMetaData(
49 scoped_ptr<autofill::AutocheckoutPageMetaData> page_meta_data); 47 scoped_ptr<AutocheckoutPageMetaData> page_meta_data);
50 48
51 // Called when a page containing forms is loaded. 49 // Called when a page containing forms is loaded.
52 void OnFormsSeen(); 50 void OnFormsSeen();
53 51
54 // Causes the Autocheckout bubble to be displayed if the user hasn't seen it 52 // Causes the Autocheckout bubble to be displayed if the user hasn't seen it
55 // yet for the current page. |frame_url| is the page where Autocheckout is 53 // yet for the current page. |frame_url| is the page where Autocheckout is
56 // being initiated. |ssl_status| is the SSL status of the page. |native_view| 54 // being initiated. |ssl_status| is the SSL status of the page. |native_view|
57 // is the parent view of the bubble. |bounding_box| is the bounding box of the 55 // is the parent view of the bubble. |bounding_box| is the bounding box of the
58 // input field in focus. Returns true if the bubble was shown and false 56 // input field in focus. Returns true if the bubble was shown and false
59 // otherwise. 57 // otherwise.
(...skipping 25 matching lines...) Expand all
85 // Credit card verification code. 83 // Credit card verification code.
86 string16 cvv_; 84 string16 cvv_;
87 85
88 // Profile built using the data supplied by requestAutocomplete dialog. 86 // Profile built using the data supplied by requestAutocomplete dialog.
89 scoped_ptr<AutofillProfile> profile_; 87 scoped_ptr<AutofillProfile> profile_;
90 88
91 // Credit card built using the data supplied by requestAutocomplete dialog. 89 // Credit card built using the data supplied by requestAutocomplete dialog.
92 scoped_ptr<CreditCard> credit_card_; 90 scoped_ptr<CreditCard> credit_card_;
93 91
94 // Autocheckout specific page meta data. 92 // Autocheckout specific page meta data.
95 scoped_ptr<autofill::AutocheckoutPageMetaData> page_meta_data_; 93 scoped_ptr<AutocheckoutPageMetaData> page_meta_data_;
96 94
97 // Whether or not the Autocheckout bubble has been displayed to the user for 95 // Whether or not the Autocheckout bubble has been displayed to the user for
98 // the current forms. Ensures the Autocheckout bubble is only shown to a 96 // the current forms. Ensures the Autocheckout bubble is only shown to a
99 // user once per pageview. 97 // user once per pageview.
100 bool autocheckout_bubble_shown_; 98 bool autocheckout_bubble_shown_;
101 99
102 base::WeakPtrFactory<AutocheckoutManager> weak_ptr_factory_; 100 base::WeakPtrFactory<AutocheckoutManager> weak_ptr_factory_;
103 101
104 DISALLOW_COPY_AND_ASSIGN(AutocheckoutManager); 102 DISALLOW_COPY_AND_ASSIGN(AutocheckoutManager);
105 }; 103 };
106 104
105 } // namespace autofill
106
107 #endif // CHROME_BROWSER_AUTOFILL_AUTOCHECKOUT_MANAGER_H_ 107 #endif // CHROME_BROWSER_AUTOFILL_AUTOCHECKOUT_MANAGER_H_
OLDNEW
« no previous file with comments | « chrome/browser/autofill/autocheckout_infobar_delegate.cc ('k') | chrome/browser/autofill/autocheckout_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698