| OLD | NEW |
| 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 #include "ui/views/window/dialog_delegate.h" | 5 #include "ui/views/window/dialog_delegate.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "ui/accessibility/ax_view_state.h" | 8 #include "ui/accessibility/ax_view_state.h" |
| 9 #include "ui/base/l10n/l10n_util.h" | 9 #include "ui/base/l10n/l10n_util.h" |
| 10 #include "ui/strings/grit/ui_strings.h" | 10 #include "ui/strings/grit/ui_strings.h" |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 // widgets to prevent top-level window behavior (independent movement, etc). | 70 // widgets to prevent top-level window behavior (independent movement, etc). |
| 71 params.child = parent && (delegate->GetModalType() == ui::MODAL_TYPE_CHILD); | 71 params.child = parent && (delegate->GetModalType() == ui::MODAL_TYPE_CHILD); |
| 72 widget->Init(params); | 72 widget->Init(params); |
| 73 return widget; | 73 return widget; |
| 74 } | 74 } |
| 75 | 75 |
| 76 View* DialogDelegate::CreateExtraView() { | 76 View* DialogDelegate::CreateExtraView() { |
| 77 return NULL; | 77 return NULL; |
| 78 } | 78 } |
| 79 | 79 |
| 80 bool DialogDelegate::GetExtraViewPadding(int* padding) { |
| 81 return false; |
| 82 } |
| 83 |
| 80 View* DialogDelegate::CreateTitlebarExtraView() { | 84 View* DialogDelegate::CreateTitlebarExtraView() { |
| 81 return NULL; | 85 return NULL; |
| 82 } | 86 } |
| 83 | 87 |
| 84 View* DialogDelegate::CreateFootnoteView() { | 88 View* DialogDelegate::CreateFootnoteView() { |
| 85 return NULL; | 89 return NULL; |
| 86 } | 90 } |
| 87 | 91 |
| 88 bool DialogDelegate::Cancel() { | 92 bool DialogDelegate::Cancel() { |
| 89 return true; | 93 return true; |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 state->role = ui::AX_ROLE_DIALOG; | 244 state->role = ui::AX_ROLE_DIALOG; |
| 241 } | 245 } |
| 242 | 246 |
| 243 void DialogDelegateView::ViewHierarchyChanged( | 247 void DialogDelegateView::ViewHierarchyChanged( |
| 244 const ViewHierarchyChangedDetails& details) { | 248 const ViewHierarchyChangedDetails& details) { |
| 245 if (details.is_add && details.child == this && GetWidget()) | 249 if (details.is_add && details.child == this && GetWidget()) |
| 246 NotifyAccessibilityEvent(ui::AX_EVENT_ALERT, true); | 250 NotifyAccessibilityEvent(ui::AX_EVENT_ALERT, true); |
| 247 } | 251 } |
| 248 | 252 |
| 249 } // namespace views | 253 } // namespace views |
| OLD | NEW |