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

Unified Diff: chrome/browser/ui/ash/network_connect_delegate_chromeos.cc

Issue 2434683003: Move NetworkStateNotifier and NetworkConnect from src/ui (Closed)
Patch Set: Fix virtuals 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/ash/network_connect_delegate_chromeos.cc
diff --git a/chrome/browser/ui/ash/network_connect_delegate_chromeos.cc b/chrome/browser/ui/ash/network_connect_delegate_chromeos.cc
deleted file mode 100644
index 4342b467631ded7885af5a321b951f03cc45054b..0000000000000000000000000000000000000000
--- a/chrome/browser/ui/ash/network_connect_delegate_chromeos.cc
+++ /dev/null
@@ -1,71 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "chrome/browser/ui/ash/network_connect_delegate_chromeos.h"
-
-#include "ash/common/session/session_state_delegate.h"
-#include "ash/common/wm_shell.h"
-#include "ash/shell.h"
-#include "chrome/browser/chromeos/enrollment_dialog_view.h"
-#include "chrome/browser/chromeos/sim_dialog_delegate.h"
-#include "chrome/browser/ui/ash/system_tray_client.h"
-#include "chrome/browser/ui/webui/chromeos/mobile_setup_dialog.h"
-
-namespace {
-
-bool IsUIAvailable() {
- return ash::WmShell::HasInstance() &&
- !ash::WmShell::Get()->GetSessionStateDelegate()->IsScreenLocked();
-}
-
-gfx::NativeWindow GetNativeWindow() {
- int container_id = SystemTrayClient::GetDialogParentContainerId();
- return ash::Shell::GetContainer(ash::Shell::GetPrimaryRootWindow(),
- container_id);
-}
-
-} // namespace
-
-namespace chromeos {
-
-NetworkConnectDelegateChromeOS::NetworkConnectDelegateChromeOS() {}
-
-NetworkConnectDelegateChromeOS::~NetworkConnectDelegateChromeOS() {}
-
-void NetworkConnectDelegateChromeOS::ShowNetworkConfigure(
- const std::string& network_id) {
- if (!IsUIAvailable())
- return;
- SystemTrayClient::Get()->ShowNetworkConfigure(network_id);
-}
-
-void NetworkConnectDelegateChromeOS::ShowNetworkSettings(
- const std::string& network_id) {
- if (!IsUIAvailable())
- return;
- SystemTrayClient::Get()->ShowNetworkSettings(network_id);
-}
-
-bool NetworkConnectDelegateChromeOS::ShowEnrollNetwork(
- const std::string& network_id) {
- if (!IsUIAvailable())
- return false;
- return enrollment::CreateDialog(network_id, GetNativeWindow());
-}
-
-void NetworkConnectDelegateChromeOS::ShowMobileSimDialog() {
- if (!IsUIAvailable())
- return;
- SimDialogDelegate::ShowDialog(GetNativeWindow(),
- SimDialogDelegate::SIM_DIALOG_UNLOCK);
-}
-
-void NetworkConnectDelegateChromeOS::ShowMobileSetupDialog(
- const std::string& network_id) {
- if (!IsUIAvailable())
- return;
- MobileSetupDialog::ShowByNetworkId(network_id);
-}
-
-} // namespace chromeos
« no previous file with comments | « chrome/browser/ui/ash/network_connect_delegate_chromeos.h ('k') | chrome/browser/ui/ash/vpn_delegate_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698