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

Unified Diff: chrome/browser/chromeos/net/onc_utils.cc

Issue 22796014: Eliminate c/b/chromeos/options/network_connect.cc (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 4 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 | « chrome/browser/chromeos/net/onc_utils.h ('k') | chrome/browser/chromeos/options/network_connect.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/net/onc_utils.cc
diff --git a/chrome/browser/chromeos/net/onc_utils.cc b/chrome/browser/chromeos/net/onc_utils.cc
index 9a66fba1e3c79823f7efe132002b47f809a8d564..853d52ba1f5acdb7643beacef072e2f597f6bfe8 100644
--- a/chrome/browser/chromeos/net/onc_utils.cc
+++ b/chrome/browser/chromeos/net/onc_utils.cc
@@ -9,8 +9,10 @@
#include "base/logging.h"
#include "base/values.h"
#include "chrome/browser/chromeos/login/user.h"
+#include "chrome/browser/chromeos/login/user_manager.h"
#include "chrome/browser/chromeos/ui_proxy_config.h"
#include "chrome/browser/prefs/proxy_config_dictionary.h"
+#include "chromeos/network/managed_network_configuration_handler.h"
#include "chromeos/network/network_configuration_handler.h"
#include "chromeos/network/network_handler.h"
#include "chromeos/network/network_profile.h"
@@ -229,5 +231,14 @@ void ImportNetworksForUser(const chromeos::User* user,
}
}
+const base::DictionaryValue* FindPolicyForActiveUser(
+ const std::string& guid,
+ onc::ONCSource* onc_source) {
+ const User* user = UserManager::Get()->GetActiveUser();
+ std::string username_hash = user ? user->username_hash() : std::string();
+ return NetworkHandler::Get()->managed_network_configuration_handler()->
+ FindPolicyByGUID(username_hash, guid, onc_source);
+}
+
} // namespace onc
} // namespace chromeos
« no previous file with comments | « chrome/browser/chromeos/net/onc_utils.h ('k') | chrome/browser/chromeos/options/network_connect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698