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

Side by Side Diff: chrome/browser/ui/webui/settings/chromeos/internet_handler.cc

Issue 2426473009: mash: Place views Wi-Fi network config dialogs in correct window parent (Closed)
Patch Set: review comments 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/webui/settings/chromeos/internet_handler.h" 5 #include "chrome/browser/ui/webui/settings/chromeos/internet_handler.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/values.h" 8 #include "base/values.h"
9 #include "chrome/browser/chromeos/options/network_config_view.h" 9 #include "chrome/browser/chromeos/options/network_config_view.h"
10 #include "chrome/browser/chromeos/profiles/profile_helper.h" 10 #include "chrome/browser/chromeos/profiles/profile_helper.h"
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 if (network->type() == shill::kTypeVPN && 114 if (network->type() == shill::kTypeVPN &&
115 network->vpn_provider_type() == shill::kProviderThirdPartyVpn) { 115 network->vpn_provider_type() == shill::kProviderThirdPartyVpn) {
116 // Request that the third-party VPN provider used by the |network| show a 116 // Request that the third-party VPN provider used by the |network| show a
117 // configuration dialog for it. 117 // configuration dialog for it.
118 VpnServiceFactory::GetForBrowserContext(GetProfileForPrimaryUser()) 118 VpnServiceFactory::GetForBrowserContext(GetProfileForPrimaryUser())
119 ->SendShowConfigureDialogToExtension( 119 ->SendShowConfigureDialogToExtension(
120 network->third_party_vpn_provider_extension_id(), network->name()); 120 network->third_party_vpn_provider_extension_id(), network->name());
121 return; 121 return;
122 } 122 }
123 123
124 NetworkConfigView::Show(service_path, GetNativeWindow()); 124 NetworkConfigView::ShowInParent(network->guid(), GetNativeWindow());
125 } 125 }
126 126
127 gfx::NativeWindow InternetHandler::GetNativeWindow() const { 127 gfx::NativeWindow InternetHandler::GetNativeWindow() const {
128 return web_ui()->GetWebContents()->GetTopLevelNativeWindow(); 128 return web_ui()->GetWebContents()->GetTopLevelNativeWindow();
129 } 129 }
130 130
131 } // namespace settings 131 } // namespace settings
132 } // namespace chromeos 132 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698