| 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 "chrome/browser/chromeos/external_protocol_dialog.h" | 5 #include "chrome/browser/chromeos/external_protocol_dialog.h" |
| 6 | 6 |
| 7 #include "base/metrics/histogram.h" | 7 #include "base/metrics/histogram.h" |
| 8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
| 9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
| 10 #include "chrome/browser/external_protocol/external_protocol_handler.h" | 10 #include "chrome/browser/external_protocol/external_protocol_handler.h" |
| (...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 message_box_view_->SetCheckBoxLabel( | 117 message_box_view_->SetCheckBoxLabel( |
| 118 l10n_util::GetStringUTF16(IDS_EXTERNAL_PROTOCOL_CHECKBOX_TEXT)); | 118 l10n_util::GetStringUTF16(IDS_EXTERNAL_PROTOCOL_CHECKBOX_TEXT)); |
| 119 | 119 |
| 120 gfx::NativeWindow parent_window; | 120 gfx::NativeWindow parent_window; |
| 121 if (web_contents) { | 121 if (web_contents) { |
| 122 parent_window = web_contents->GetView()->GetTopLevelNativeWindow(); | 122 parent_window = web_contents->GetView()->GetTopLevelNativeWindow(); |
| 123 } else { | 123 } else { |
| 124 // Dialog is top level if we don't have a web_contents associated with us. | 124 // Dialog is top level if we don't have a web_contents associated with us. |
| 125 parent_window = NULL; | 125 parent_window = NULL; |
| 126 } | 126 } |
| 127 views::Widget::CreateWindowWithParent(this, parent_window)->Show(); | 127 views::DialogDelegate::CreateDialogWidget(this, NULL, parent_window)->Show(); |
| 128 } | 128 } |
| OLD | NEW |