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

Unified Diff: chrome/browser/ui/webui/chromeos/network_ui.cc

Issue 2426473009: mash: Place views Wi-Fi network config dialogs in correct window parent (Closed)
Patch Set: rebase Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/chromeos/network_ui.cc
diff --git a/chrome/browser/ui/webui/chromeos/network_ui.cc b/chrome/browser/ui/webui/chromeos/network_ui.cc
index 8dfc7c2b4edf69bff47da32131a69f4f470a542a..fa5cef1f60f7516f849d846d24e9b5e5f5160583 100644
--- a/chrome/browser/ui/webui/chromeos/network_ui.cc
+++ b/chrome/browser/ui/webui/chromeos/network_ui.cc
@@ -28,6 +28,7 @@
#include "third_party/cros_system_api/dbus/service_constants.h"
#include "ui/base/l10n/l10n_util.h"
#include "ui/chromeos/strings/grit/ui_chromeos_strings.h"
+#include "ui/views/widget/widget_parent.h"
namespace chromeos {
@@ -144,8 +145,10 @@ class NetworkConfigMessageHandler : public content::WebUIMessageHandler {
std::string shill_type = (onc_type == ::onc::network_type::kVPN)
? shill::kTypeVPN
: shill::kTypeWifi;
- NetworkConfigView::ShowForType(
- shill_type, web_ui()->GetWebContents()->GetTopLevelNativeWindow());
+ views::WidgetParent widget_parent;
+ widget_parent.native_parent =
+ web_ui()->GetWebContents()->GetTopLevelNativeWindow();
+ NetworkConfigView::ShowForType(shill_type, widget_parent);
}
base::WeakPtrFactory<NetworkConfigMessageHandler> weak_ptr_factory_;

Powered by Google App Engine
This is Rietveld 408576698