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/ui/views/external_protocol_dialog.h" | 5 #include "chrome/browser/ui/views/external_protocol_dialog.h" |
6 | 6 |
7 #include "base/metrics/histogram.h" | 7 #include "base/metrics/histogram.h" |
8 #include "base/strings/string_util.h" | 8 #include "base/strings/string_util.h" |
9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/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 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 params.message_width = kMessageWidth; | 128 params.message_width = kMessageWidth; |
129 message_box_view_ = new views::MessageBoxView(params); | 129 message_box_view_ = new views::MessageBoxView(params); |
130 message_box_view_->SetCheckBoxLabel(delegate_->GetCheckboxText()); | 130 message_box_view_->SetCheckBoxLabel(delegate_->GetCheckboxText()); |
131 | 131 |
132 // Dialog is top level if we don't have a web_contents associated with us. | 132 // Dialog is top level if we don't have a web_contents associated with us. |
133 WebContents* web_contents = tab_util::GetWebContentsByID( | 133 WebContents* web_contents = tab_util::GetWebContentsByID( |
134 render_process_host_id_, routing_id_); | 134 render_process_host_id_, routing_id_); |
135 gfx::NativeWindow parent_window = NULL; | 135 gfx::NativeWindow parent_window = NULL; |
136 if (web_contents) | 136 if (web_contents) |
137 parent_window = web_contents->GetTopLevelNativeWindow(); | 137 parent_window = web_contents->GetTopLevelNativeWindow(); |
138 CreateBrowserModalDialogViews(this, parent_window)->Show(); | 138 CreateAppModalDialogViews(this, parent_window)->Show(); |
139 } | 139 } |
OLD | NEW |