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

Side by Side Diff: chrome/browser/ui/views/payments/payment_request_dialog_view.h

Issue 2881643002: Focus first invalid field of payment request editor (Closed)
Patch Set: Rebase Created 3 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_PAYMENTS_PAYMENT_REQUEST_DIALOG_VIEW_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_DIALOG_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_DIALOG_VIEW_H_ 6 #define CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_DIALOG_VIEW_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 10
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 virtual void OnCvcPromptShown() = 0; 79 virtual void OnCvcPromptShown() = 0;
80 }; 80 };
81 81
82 // Build a Dialog around the PaymentRequest object. |observer| is used to 82 // Build a Dialog around the PaymentRequest object. |observer| is used to
83 // be notified of dialog events as they happen (but may be NULL) and should 83 // be notified of dialog events as they happen (but may be NULL) and should
84 // outlive this object. 84 // outlive this object.
85 PaymentRequestDialogView(PaymentRequest* request, 85 PaymentRequestDialogView(PaymentRequest* request,
86 PaymentRequestDialogView::ObserverForTest* observer); 86 PaymentRequestDialogView::ObserverForTest* observer);
87 ~PaymentRequestDialogView() override; 87 ~PaymentRequestDialogView() override;
88 88
89 // views::View
90 void RequestFocus() override;
91
89 // views::WidgetDelegate: 92 // views::WidgetDelegate:
90 ui::ModalType GetModalType() const override; 93 ui::ModalType GetModalType() const override;
91 views::View* GetInitiallyFocusedView() override; 94 views::View* GetInitiallyFocusedView() override;
92 95
93 // views::DialogDelegate: 96 // views::DialogDelegate:
94 bool Cancel() override; 97 bool Cancel() override;
95 bool ShouldShowCloseButton() const override; 98 bool ShouldShowCloseButton() const override;
96 int GetDialogButtons() const override; 99 int GetDialogButtons() const override;
97 100
98 // payments::PaymentRequestDialog: 101 // payments::PaymentRequestDialog:
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 // Used when the dialog is being closed to avoid re-entrancy into the 187 // Used when the dialog is being closed to avoid re-entrancy into the
185 // controller_map_. 188 // controller_map_.
186 bool being_closed_; 189 bool being_closed_;
187 190
188 DISALLOW_COPY_AND_ASSIGN(PaymentRequestDialogView); 191 DISALLOW_COPY_AND_ASSIGN(PaymentRequestDialogView);
189 }; 192 };
190 193
191 } // namespace payments 194 } // namespace payments
192 195
193 #endif // CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_DIALOG_VIEW_H_ 196 #endif // CHROME_BROWSER_UI_VIEWS_PAYMENTS_PAYMENT_REQUEST_DIALOG_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698