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

Unified Diff: ash/system/chromeos/network/vpn_delegate.cc

Issue 2109293002: mash: Convert system tray network item to wm common types (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tweak string Created 4 years, 6 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
« no previous file with comments | « ash/system/chromeos/network/vpn_delegate.h ('k') | ash/system/chromeos/network/vpn_list_view.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/chromeos/network/vpn_delegate.cc
diff --git a/ash/system/chromeos/network/vpn_delegate.cc b/ash/system/chromeos/network/vpn_delegate.cc
deleted file mode 100644
index 1628d494bc21336eaab630fb62cfde9247c75df3..0000000000000000000000000000000000000000
--- a/ash/system/chromeos/network/vpn_delegate.cc
+++ /dev/null
@@ -1,54 +0,0 @@
-// Copyright 2015 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 "ash/system/chromeos/network/vpn_delegate.h"
-
-#include "chromeos/network/network_state.h"
-#include "third_party/cros_system_api/dbus/service_constants.h"
-
-namespace ash {
-
-VPNProvider::Key::Key() : third_party(false) {}
-
-VPNProvider::Key::Key(const std::string& extension_id)
- : third_party(true), extension_id(extension_id) {}
-
-bool VPNProvider::Key::operator==(const Key& other) const {
- return other.third_party == third_party && other.extension_id == extension_id;
-}
-
-bool VPNProvider::Key::MatchesNetwork(
- const chromeos::NetworkState& network) const {
- if (network.type() != shill::kTypeVPN)
- return false;
- const bool network_uses_third_party_provider =
- network.vpn_provider_type() == shill::kProviderThirdPartyVpn;
- if (!third_party)
- return !network_uses_third_party_provider;
- return network_uses_third_party_provider &&
- network.third_party_vpn_provider_extension_id() == extension_id;
-}
-
-VPNProvider::VPNProvider(const Key& key, const std::string& name)
- : key(key), name(name) {}
-
-VPNDelegate::Observer::~Observer() {}
-
-VPNDelegate::VPNDelegate() {}
-
-VPNDelegate::~VPNDelegate() {}
-
-void VPNDelegate::AddObserver(Observer* observer) {
- observer_list_.AddObserver(observer);
-}
-
-void VPNDelegate::RemoveObserver(Observer* observer) {
- observer_list_.RemoveObserver(observer);
-}
-
-void VPNDelegate::NotifyObservers() {
- FOR_EACH_OBSERVER(Observer, observer_list_, OnVPNProvidersChanged());
-}
-
-} // namespace ash
« no previous file with comments | « ash/system/chromeos/network/vpn_delegate.h ('k') | ash/system/chromeos/network/vpn_list_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698