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

Side by Side Diff: chrome/browser/ui/views/autofill/autofill_dialog_views.h

Issue 12221040: Interactive autofill: Handle Online Wallet being unavailable. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . 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) 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_VIEWS_AUTOFILL_AUTOFILL_DIALOG_VIEWS_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_AUTOFILL_AUTOFILL_DIALOG_VIEWS_H_
6 #define CHROME_BROWSER_UI_VIEWS_AUTOFILL_AUTOFILL_DIALOG_VIEWS_H_ 6 #define CHROME_BROWSER_UI_VIEWS_AUTOFILL_AUTOFILL_DIALOG_VIEWS_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "chrome/browser/ui/autofill/autofill_dialog_controller.h" 10 #include "chrome/browser/ui/autofill/autofill_dialog_controller.h"
(...skipping 16 matching lines...) Expand all
27 class Image; 27 class Image;
28 } 28 }
29 29
30 namespace views { 30 namespace views {
31 class Checkbox; 31 class Checkbox;
32 class Combobox; 32 class Combobox;
33 class FocusManager; 33 class FocusManager;
34 class ImageButton; 34 class ImageButton;
35 class ImageView; 35 class ImageView;
36 class Label; 36 class Label;
37 class Link;
37 class MenuRunner; 38 class MenuRunner;
38 class TextButton; 39 class TextButton;
39 class Textfield; 40 class Textfield;
40 class WebView; 41 class WebView;
41 } 42 }
42 43
43 namespace ui { 44 namespace ui {
44 class ComboboxModel; 45 class ComboboxModel;
45 class KeyEvent; 46 class KeyEvent;
46 } 47 }
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 virtual void PaintChildren(gfx::Canvas* canvas) OVERRIDE; 134 virtual void PaintChildren(gfx::Canvas* canvas) OVERRIDE;
134 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; 135 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE;
135 136
136 private: 137 private:
137 views::Textfield* textfield_; 138 views::Textfield* textfield_;
138 bool invalid_; 139 bool invalid_;
139 140
140 DISALLOW_COPY_AND_ASSIGN(DecoratedTextfield); 141 DISALLOW_COPY_AND_ASSIGN(DecoratedTextfield);
141 }; 142 };
142 143
143 // An area for notifications. Some types of notifications point at stuff. 144 // An area for notifications. Some notifications point at the account chooser.
144 class NotificationArea : public views::View { 145 class NotificationArea : public views::View {
145 public: 146 public:
146 NotificationArea(); 147 NotificationArea();
147 virtual ~NotificationArea(); 148 virtual ~NotificationArea();
148 149
150 void set_arrow_centering_anchor(views::View* arrow_centering_anchor) {
151 arrow_centering_anchor_ = arrow_centering_anchor;
152 }
153
149 void SetNotification(const DialogNotification& notification); 154 void SetNotification(const DialogNotification& notification);
150 155
151 // views::View implementation. 156 // views::View implementation.
152 virtual std::string GetClassName() const OVERRIDE; 157 virtual std::string GetClassName() const OVERRIDE;
153 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; 158 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE;
154 159
155 private: 160 private:
156 views::Label* label_; 161 views::Label* label_;
162
163 // If |notification_.HasArrow()| is true, the arrow should point at this.
164 views::View* arrow_centering_anchor_; // weak.
165
157 DialogNotification notification_; 166 DialogNotification notification_;
158 167
159 DISALLOW_COPY_AND_ASSIGN(NotificationArea); 168 DISALLOW_COPY_AND_ASSIGN(NotificationArea);
160 }; 169 };
161 170
162 typedef std::map<const DetailInput*, DecoratedTextfield*> TextfieldMap; 171 typedef std::map<const DetailInput*, DecoratedTextfield*> TextfieldMap;
163 typedef std::map<const DetailInput*, views::Combobox*> ComboboxMap; 172 typedef std::map<const DetailInput*, views::Combobox*> ComboboxMap;
164 173
165 // A view that packs a label on the left and some related controls 174 // A view that packs a label on the left and some related controls
166 // on the right. 175 // on the right.
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
333 // Somewhere to show notification messages about errors, warnings, or promos. 342 // Somewhere to show notification messages about errors, warnings, or promos.
334 NotificationArea* notification_area_; 343 NotificationArea* notification_area_;
335 344
336 // The checkbox that controls whether to use the billing details for shipping 345 // The checkbox that controls whether to use the billing details for shipping
337 // as well. 346 // as well.
338 views::Checkbox* use_billing_for_shipping_; 347 views::Checkbox* use_billing_for_shipping_;
339 348
340 // Runs the suggestion menu (triggered by each section's |suggested_button|. 349 // Runs the suggestion menu (triggered by each section's |suggested_button|.
341 scoped_ptr<views::MenuRunner> menu_runner_; 350 scoped_ptr<views::MenuRunner> menu_runner_;
342 351
343 // The link that initiates the sign in flow. 352 // A link to allow choosing different accounts to pay with.
344 views::Link* sign_in_link_; 353 views::Link* account_chooser_link_;
345 354
346 // View to host the signin dialog and related controls. 355 // View to host the signin dialog and related controls.
347 views::View* sign_in_container_; 356 views::View* sign_in_container_;
348 357
349 // TextButton displayed during sign-in. Clicking cancels sign-in and returns 358 // TextButton displayed during sign-in. Clicking cancels sign-in and returns
350 // to the main flow. 359 // to the main flow.
351 views::TextButton* cancel_sign_in_; 360 views::TextButton* cancel_sign_in_;
352 361
353 // A WebView to that navigates to a Google sign-in page to allow the user to 362 // A WebView to that navigates to a Google sign-in page to allow the user to
354 // sign-in. 363 // sign-in.
(...skipping 17 matching lines...) Expand all
372 381
373 // The focus manager for |window_|. 382 // The focus manager for |window_|.
374 views::FocusManager* focus_manager_; 383 views::FocusManager* focus_manager_;
375 384
376 DISALLOW_COPY_AND_ASSIGN(AutofillDialogViews); 385 DISALLOW_COPY_AND_ASSIGN(AutofillDialogViews);
377 }; 386 };
378 387
379 } // namespace autofill 388 } // namespace autofill
380 389
381 #endif // CHROME_BROWSER_UI_VIEWS_AUTOFILL_AUTOFILL_DIALOG_VIEWS_H_ 390 #endif // CHROME_BROWSER_UI_VIEWS_AUTOFILL_AUTOFILL_DIALOG_VIEWS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698