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

Unified Diff: chrome/browser/autofill/autofill_popup_view.h

Issue 9187009: Basic Drawn text for new GTK Autofill popup. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Responding to Comments Created 8 years, 11 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 side-by-side diff with in-line comments
Download patch
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..9153814c56b134d7cc6827cd50a0a02a92b0e26f 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.
+ 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,22 @@ 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.
+ virtual void ShowInternal() = 0;
+
+ const std::vector<string16>& autofill_values() const {
+ return autofill_values_;
+ }
+ const std::vector<string16>& autofill_labels() const {
+ return autofill_labels_;
+ }
+ const std::vector<string16>& autofill_icons() const {
+ return autofill_icons_;
+ }
+ const int separator_index() const { return separator_index_; }
+
private:
// content::NotificationObserver method override.
virtual void Observe(int type,
@@ -49,6 +68,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.
+ 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 separates the returned values
+ // from the Autofill options).
+ int separator_index_;
};
#endif // CHROME_BROWSER_AUTOFILL_AUTOFILL_POPUP_VIEW_H_

Powered by Google App Engine
This is Rietveld 408576698