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

Side by Side Diff: ui/views/window/dialog_delegate.cc

Issue 2868203002: Replace Dialog.Delegate.Creation with Dialog.DialogDelegate.Create. (Closed)
Patch Set: fix dialog name in comment 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 (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 <utility> 7 #include <utility>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/metrics/histogram_macros.h" 10 #include "base/metrics/histogram_macros.h"
(...skipping 15 matching lines...) Expand all
26 #if defined(OS_WIN) 26 #if defined(OS_WIN)
27 #include "ui/base/win/shell.h" 27 #include "ui/base/win/shell.h"
28 #endif 28 #endif
29 29
30 namespace views { 30 namespace views {
31 31
32 //////////////////////////////////////////////////////////////////////////////// 32 ////////////////////////////////////////////////////////////////////////////////
33 // DialogDelegate: 33 // DialogDelegate:
34 34
35 DialogDelegate::DialogDelegate() : supports_custom_frame_(true) { 35 DialogDelegate::DialogDelegate() : supports_custom_frame_(true) {
36 UMA_HISTOGRAM_BOOLEAN("Dialog.Delegate.Creation", true); 36 UMA_HISTOGRAM_BOOLEAN("Dialog.DialogDelegate.Create", true);
37 } 37 }
38 38
39 DialogDelegate::~DialogDelegate() {} 39 DialogDelegate::~DialogDelegate() {}
40 40
41 // static 41 // static
42 Widget* DialogDelegate::CreateDialogWidget(WidgetDelegate* delegate, 42 Widget* DialogDelegate::CreateDialogWidget(WidgetDelegate* delegate,
43 gfx::NativeWindow context, 43 gfx::NativeWindow context,
44 gfx::NativeView parent) { 44 gfx::NativeView parent) {
45 views::Widget* widget = new views::Widget; 45 views::Widget* widget = new views::Widget;
46 views::Widget::InitParams params = 46 views::Widget::InitParams params =
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 node_data->role = ui::AX_ROLE_DIALOG; 269 node_data->role = ui::AX_ROLE_DIALOG;
270 } 270 }
271 271
272 void DialogDelegateView::ViewHierarchyChanged( 272 void DialogDelegateView::ViewHierarchyChanged(
273 const ViewHierarchyChangedDetails& details) { 273 const ViewHierarchyChangedDetails& details) {
274 if (details.is_add && details.child == this && GetWidget()) 274 if (details.is_add && details.child == this && GetWidget())
275 NotifyAccessibilityEvent(ui::AX_EVENT_ALERT, true); 275 NotifyAccessibilityEvent(ui::AX_EVENT_ALERT, true);
276 } 276 }
277 277
278 } // namespace views 278 } // namespace views
OLDNEW
« tools/metrics/histograms/histograms.xml ('K') | « tools/metrics/histograms/histograms.xml ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698