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

Side by Side Diff: chrome/browser/chromeos/cros/network_library.h

Issue 8804020: Set onc_source UI data parameter when importing ONC. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 9 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_
6 #define CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ 6 #define CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_
7 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/compiler_specific.h" 13 #include "base/compiler_specific.h"
14 #include "base/gtest_prod_util.h" 14 #include "base/gtest_prod_util.h"
15 #include "base/memory/scoped_ptr.h" 15 #include "base/memory/scoped_ptr.h"
16 #include "base/memory/scoped_vector.h" 16 #include "base/memory/scoped_vector.h"
17 #include "base/memory/singleton.h" 17 #include "base/memory/singleton.h"
18 #include "base/observer_list.h" 18 #include "base/observer_list.h"
19 #include "base/string16.h" 19 #include "base/string16.h"
20 #include "base/timer.h" 20 #include "base/timer.h"
21 #include "chrome/browser/chromeos/cros/network_ui_data.h"
21 #include "third_party/cros/chromeos_network.h" 22 #include "third_party/cros/chromeos_network.h"
22 23
23 namespace base { 24 namespace base {
24 class DictionaryValue; 25 class DictionaryValue;
25 class Value; 26 class Value;
26 } 27 }
27 28
28 namespace chromeos { 29 namespace chromeos {
29 30
30 class NetworkDeviceParser; 31 class NetworkDeviceParser;
(...skipping 1755 matching lines...) Expand 10 before | Expand all | Expand 10 after
1786 // This will connect to a preferred network if the currently connected 1787 // This will connect to a preferred network if the currently connected
1787 // network is not preferred. This should be called when the active profile 1788 // network is not preferred. This should be called when the active profile
1788 // changes. 1789 // changes.
1789 virtual void SwitchToPreferredNetwork() = 0; 1790 virtual void SwitchToPreferredNetwork() = 0;
1790 1791
1791 // Load networks from an Open Network Configuration blob. 1792 // Load networks from an Open Network Configuration blob.
1792 // If there was an error, this will return false and |error| will be set to 1793 // If there was an error, this will return false and |error| will be set to
1793 // the error message. 1794 // the error message.
1794 virtual bool LoadOncNetworks(const std::string& onc_blob, 1795 virtual bool LoadOncNetworks(const std::string& onc_blob,
1795 const std::string& passcode, 1796 const std::string& passcode,
1797 NetworkUIData::ONCSource source,
1796 std::string* error) = 0; 1798 std::string* error) = 0;
1797 1799
1798 // This sets the active network for the network type. Note: priority order 1800 // This sets the active network for the network type. Note: priority order
1799 // is unchanged (i.e. if a wifi network is set to active, but an ethernet 1801 // is unchanged (i.e. if a wifi network is set to active, but an ethernet
1800 // network is still active, active_network() will still return the ethernet 1802 // network is still active, active_network() will still return the ethernet
1801 // network). Other networks of the same type will become inactive. 1803 // network). Other networks of the same type will become inactive.
1802 // Used for testing. 1804 // Used for testing.
1803 virtual bool SetActiveNetwork(ConnectionType type, 1805 virtual bool SetActiveNetwork(ConnectionType type,
1804 const std::string& service_path) = 0; 1806 const std::string& service_path) = 0;
1805 1807
1806 // Factory function, creates a new instance and returns ownership. 1808 // Factory function, creates a new instance and returns ownership.
1807 // For normal usage, access the singleton via CrosLibrary::Get(). 1809 // For normal usage, access the singleton via CrosLibrary::Get().
1808 static NetworkLibrary* GetImpl(bool stub); 1810 static NetworkLibrary* GetImpl(bool stub);
1809 }; 1811 };
1810 1812
1811 } // namespace chromeos 1813 } // namespace chromeos
1812 1814
1813 #endif // CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_ 1815 #endif // CHROME_BROWSER_CHROMEOS_CROS_NETWORK_LIBRARY_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/cros/mock_network_library.h ('k') | chrome/browser/chromeos/cros/network_library.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698