Chromium Code Reviews| Index: chrome/browser/autofill/autofill_popup_view.h |
| diff --git a/chrome/browser/autofill/autofill_popup_view.h b/chrome/browser/autofill/autofill_popup_view.h |
| index bde5cd226e587e51233dcbb3e900f006a55f0d70..a7f94c5481d0d759038f9cb51ecfb5962a903d22 100644 |
| --- a/chrome/browser/autofill/autofill_popup_view.h |
| +++ b/chrome/browser/autofill/autofill_popup_view.h |
| @@ -6,6 +6,8 @@ |
| #define CHROME_BROWSER_AUTOFILL_AUTOFILL_POPUP_VIEW_H_ |
| #pragma once |
| +#include <vector> |
| + |
| #include "base/compiler_specific.h" |
| #include "base/string16.h" |
| #include "content/public/browser/notification_registrar.h" |
| @@ -25,11 +27,12 @@ class AutofillPopupView : public content::NotificationObserver { |
| virtual void Hide() = 0; |
| // Display the autofill popup and fill it in with the values passed in. |
| - virtual void Show(const std::vector<string16>& autofill_values, |
| - const std::vector<string16>& autofill_labels, |
| - const std::vector<string16>& autofill_icons, |
| - const std::vector<int>& autofill_unique_ids, |
| - int separator_index) = 0; |
| + // Platform independent work. |
|
Ilya Sherman
2012/01/11 23:36:29
nit: "Platform-independent"
csharp
2012/01/12 19:39:11
Done.
|
| + void Show(const std::vector<string16>& autofill_values, |
| + const std::vector<string16>& autofill_labels, |
| + const std::vector<string16>& autofill_icons, |
| + const std::vector<int>& autofill_unique_ids, |
| + int separator_index); |
| void set_element_bounds(const gfx::Rect& bounds) { |
| @@ -38,6 +41,18 @@ class AutofillPopupView : public content::NotificationObserver { |
| const gfx::Rect& element_bounds() { return element_bounds_; } |
| + protected: |
| + // Display the autofill popup and fill it in with the values passed in. |
| + // Platform dependent work. |
|
Ilya Sherman
2012/01/11 23:36:29
nit: "Platform-dependent"
csharp
2012/01/12 19:39:11
Done.
|
| + virtual void ShowInternal(const std::vector<string16>& autofill_values, |
| + const std::vector<string16>& autofill_labels, |
| + const std::vector<string16>& autofill_icons) = 0; |
|
Ilya Sherman
2012/01/11 23:36:29
nit: Hmm, since all of these vectors are exposed v
csharp
2012/01/12 19:39:11
I removed passing them in, since they do need to b
|
| + |
| + const std::vector<string16>& autofill_values() { return autofill_values_; } |
| + const std::vector<string16>& autofill_labels() { return autofill_labels_; } |
| + const std::vector<string16>& autofill_icons() { return autofill_icons_; } |
| + const int separator_index() { return separator_index_; } |
|
Ilya Sherman
2012/01/11 23:36:29
nit: These methods should be marked const. (Ah, c
csharp
2012/01/12 19:39:11
Done.
|
| + |
| private: |
| // content::NotificationObserver method override. |
| virtual void Observe(int type, |
| @@ -49,6 +64,16 @@ class AutofillPopupView : public content::NotificationObserver { |
| // The bounds of the text element that is the focus of the Autofill. |
| gfx::Rect element_bounds_; |
| + |
| + // The current autofill query values. |
|
Ilya Sherman
2012/01/11 23:36:29
nit: "autofill" -> "Autofill"
csharp
2012/01/12 19:39:11
Done.
|
| + std::vector<string16> autofill_values_; |
| + std::vector<string16> autofill_labels_; |
| + std::vector<string16> autofill_icons_; |
| + std::vector<int> autofill_unique_ids_; |
| + |
| + // The location of the separator index (which separator the returned values |
|
Ilya Sherman
2012/01/11 23:36:29
nit: "which separator" -> "which separates"
csharp
2012/01/12 19:39:11
Done.
|
| + // from autofill options). |
|
Ilya Sherman
2012/01/11 23:36:29
nit: "from autofill options" -> "from the Autofill
csharp
2012/01/12 19:39:11
Done.
|
| + int separator_index_; |
| }; |
| #endif // CHROME_BROWSER_AUTOFILL_AUTOFILL_POPUP_VIEW_H_ |