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

Side by Side Diff: chrome/browser/ui/views/javascript_app_modal_dialog_views.cc

Issue 15949029: Use a direct include of utf_string_conversions.h in chrome/browser/ui/, part 2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 6 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 #include "chrome/browser/ui/views/javascript_app_modal_dialog_views.h" 5 #include "chrome/browser/ui/views/javascript_app_modal_dialog_views.h"
6 6
7 #include "base/utf_string_conversions.h" 7 #include "base/strings/utf_string_conversions.h"
8 #include "chrome/browser/ui/app_modal_dialogs/javascript_app_modal_dialog.h" 8 #include "chrome/browser/ui/app_modal_dialogs/javascript_app_modal_dialog.h"
9 #include "grit/generated_resources.h" 9 #include "grit/generated_resources.h"
10 #include "ui/base/keycodes/keyboard_codes.h" 10 #include "ui/base/keycodes/keyboard_codes.h"
11 #include "ui/base/l10n/l10n_util.h" 11 #include "ui/base/l10n/l10n_util.h"
12 #include "ui/views/controls/message_box_view.h" 12 #include "ui/views/controls/message_box_view.h"
13 #include "ui/views/controls/textfield/textfield.h" 13 #include "ui/views/controls/textfield/textfield.h"
14 #include "ui/views/widget/widget.h" 14 #include "ui/views/widget/widget.h"
15 #include "ui/views/window/dialog_client_view.h" 15 #include "ui/views/window/dialog_client_view.h"
16 16
17 //////////////////////////////////////////////////////////////////////////////// 17 ////////////////////////////////////////////////////////////////////////////////
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 views::Widget::GetWidgetForNativeWindow(parent_window) : NULL; 168 views::Widget::GetWidgetForNativeWindow(parent_window) : NULL;
169 // Horizontally center the dialog window within the parent window's bounds. 169 // Horizontally center the dialog window within the parent window's bounds.
170 if (widget && parent_widget) { 170 if (widget && parent_widget) {
171 gfx::Rect bounds(widget->GetWindowBoundsInScreen()); 171 gfx::Rect bounds(widget->GetWindowBoundsInScreen());
172 gfx::Rect parent_bounds(parent_widget->GetWindowBoundsInScreen()); 172 gfx::Rect parent_bounds(parent_widget->GetWindowBoundsInScreen());
173 bounds.set_x(parent_bounds.CenterPoint().x() - bounds.width() / 2); 173 bounds.set_x(parent_bounds.CenterPoint().x() - bounds.width() / 2);
174 widget->SetBounds(bounds); 174 widget->SetBounds(bounds);
175 } 175 }
176 return d; 176 return d;
177 } 177 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698