Chromium Code Reviews| Index: ui/views/window/dialog_client_view.cc |
| diff --git a/ui/views/window/dialog_client_view.cc b/ui/views/window/dialog_client_view.cc |
| index ea23fed27516f245b46f68958c7d8d556fff1a12..2e47aa6f17f716db002954d1c4d0e2e580a8e72c 100644 |
| --- a/ui/views/window/dialog_client_view.cc |
| +++ b/ui/views/window/dialog_client_view.cc |
| @@ -214,6 +214,12 @@ void DialogClientView::Layout() { |
| bool DialogClientView::AcceleratorPressed(const ui::Accelerator& accelerator) { |
| DCHECK_EQ(accelerator.key_code(), ui::VKEY_ESCAPE); |
| + // Give the contents view a chance to handle it first. |
| + if (contents_view()->HandlesAccelerator(accelerator) && |
|
sky
2016/03/07 21:14:31
I dislike this because I think it's possible for t
Evan Stade
2016/03/08 01:34:44
How about this: remove escape handling from Dialog
|
| + contents_view()->AcceleratorPressed(accelerator)) { |
| + return true; |
| + } |
| + |
| GetWidget()->Close(); |
| return true; |
| } |