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

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

Issue 10408070: Upgrade Seperator in New Autofill UI (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 7 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
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_AUTOFILL_AUTOFILL_POPUP_VIEW_H_ 5 #ifndef CHROME_BROWSER_AUTOFILL_AUTOFILL_POPUP_VIEW_H_
6 #define CHROME_BROWSER_AUTOFILL_AUTOFILL_POPUP_VIEW_H_ 6 #define CHROME_BROWSER_AUTOFILL_AUTOFILL_POPUP_VIEW_H_
7 #pragma once 7 #pragma once
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 81
82 // Decrease the selected line by 1, properly handling wrapping. 82 // Decrease the selected line by 1, properly handling wrapping.
83 void SelectPreviousLine(); 83 void SelectPreviousLine();
84 84
85 // The user has choosen the selected line. 85 // The user has choosen the selected line.
86 bool AcceptSelectedLine(); 86 bool AcceptSelectedLine();
87 87
88 // The user has removed a suggestion. 88 // The user has removed a suggestion.
89 bool RemoveSelectedLine(); 89 bool RemoveSelectedLine();
90 90
91 // Return true if the index is the first element of a new section and should
92 // have a separator above it.
93 bool IsSeparatorIndex(int index);
94
95 // Get the resource value for the given resource, returning -1 if the 91 // Get the resource value for the given resource, returning -1 if the
96 // resource isn't recognized. 92 // resource isn't recognized.
97 int GetIconResourceID(const string16& resource_name); 93 int GetIconResourceID(const string16& resource_name);
98 94
99 private: 95 private:
96 // Returns true if the given id refers to an element that can be accepted.
97 bool CanAccept(int id);
98
100 // Returns true if the given id refers to an element that can be deleted. 99 // Returns true if the given id refers to an element that can be deleted.
101 bool CanDelete(int id); 100 bool CanDelete(int id);
102 101
103 // Returns true if the popup still has non-options entries to show the user. 102 // Returns true if the popup still has non-options entries to show the user.
104 bool HasAutofillEntries(); 103 bool HasAutofillEntries();
105 104
106 // content::NotificationObserver method override. 105 // content::NotificationObserver method override.
107 virtual void Observe(int type, 106 virtual void Observe(int type,
108 const content::NotificationSource& source, 107 const content::NotificationSource& source,
109 const content::NotificationDetails& details) OVERRIDE; 108 const content::NotificationDetails& details) OVERRIDE;
(...skipping 11 matching lines...) Expand all
121 std::vector<string16> autofill_labels_; 120 std::vector<string16> autofill_labels_;
122 std::vector<string16> autofill_icons_; 121 std::vector<string16> autofill_icons_;
123 std::vector<int> autofill_unique_ids_; 122 std::vector<int> autofill_unique_ids_;
124 123
125 // The line that is currently selected by the user. 124 // The line that is currently selected by the user.
126 // |kNoSelection| indicates that no line is currently selected. 125 // |kNoSelection| indicates that no line is currently selected.
127 int selected_line_; 126 int selected_line_;
128 }; 127 };
129 128
130 #endif // CHROME_BROWSER_AUTOFILL_AUTOFILL_POPUP_VIEW_H_ 129 #endif // CHROME_BROWSER_AUTOFILL_AUTOFILL_POPUP_VIEW_H_
OLDNEW
« no previous file with comments | « chrome/browser/autofill/autofill_popup_unittest.cc ('k') | chrome/browser/autofill/autofill_popup_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698