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

Side by Side Diff: chrome/browser/ui/webui/options/chromeos/internet_options_handler.h

Issue 544173013: Make network settings functions more closely match networkingPrivate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@issue_279351_internet_options_10c
Patch Set: Feedback Created 6 years, 3 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_UI_WEBUI_OPTIONS_CHROMEOS_INTERNET_OPTIONS_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_INTERNET_OPTIONS_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_INTERNET_OPTIONS_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_INTERNET_OPTIONS_HANDLER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 private: 44 private:
45 // OptionsPageUIHandler 45 // OptionsPageUIHandler
46 virtual void GetLocalizedValues( 46 virtual void GetLocalizedValues(
47 base::DictionaryValue* localized_strings) OVERRIDE; 47 base::DictionaryValue* localized_strings) OVERRIDE;
48 virtual void InitializePage() OVERRIDE; 48 virtual void InitializePage() OVERRIDE;
49 49
50 // WebUIMessageHandler (from OptionsPageUIHandler) 50 // WebUIMessageHandler (from OptionsPageUIHandler)
51 virtual void RegisterMessages() OVERRIDE; 51 virtual void RegisterMessages() OVERRIDE;
52 52
53 // Callbacks to set network state properties. 53 // Callbacks to set network state properties.
54 void EnableWifiCallback(const base::ListValue* args);
55 void DisableWifiCallback(const base::ListValue* args);
56 void EnableCellularCallback(const base::ListValue* args);
57 void DisableCellularCallback(const base::ListValue* args);
58 void EnableWimaxCallback(const base::ListValue* args);
59 void DisableWimaxCallback(const base::ListValue* args);
60 void ShowMorePlanInfoCallback(const base::ListValue* args); 54 void ShowMorePlanInfoCallback(const base::ListValue* args);
61 void SetApnCallback(const base::ListValue* args); 55 void SetApnCallback(const base::ListValue* args);
62 void SetApnProperties(const base::ListValue* args, 56 void SetApnProperties(const base::ListValue* args,
63 const std::string& service_path, 57 const std::string& service_path,
64 const base::DictionaryValue& shill_properties); 58 const base::DictionaryValue& shill_properties);
65 void CarrierStatusCallback(); 59 void CarrierStatusCallback();
66 void SetCarrierCallback(const base::ListValue* args); 60 void SetCarrierCallback(const base::ListValue* args);
67 void SetSimCardLockCallback(const base::ListValue* args); 61 void SimOperationCallback(const base::ListValue* args);
68 void ChangePinCallback(const base::ListValue* args); 62
69 void RefreshNetworksCallback(const base::ListValue* args); 63 // networkingPrvate callbacks
64 void DisableNetworkTypeCallback(const base::ListValue* args);
65 void EnableNetworkTypeCallback(const base::ListValue* args);
66 void GetManagedPropertiesCallback(const base::ListValue* args);
67 void RequestNetworkScanCallback(const base::ListValue* args);
68 void StartConnectCallback(const base::ListValue* args);
69 void StartDisconnectCallback(const base::ListValue* args);
70 70
71 // Retrieves a data url for a resource. 71 // Retrieves a data url for a resource.
72 std::string GetIconDataUrl(int resource_id) const; 72 std::string GetIconDataUrl(int resource_id) const;
73 73
74 // Refreshes the display of network information. 74 // Refreshes the display of network information.
75 void RefreshNetworkData(); 75 void RefreshNetworkData();
76 76
77 // Updates the display of network connection information for the details page 77 // Updates the display of network connection information for the details page
78 // if visible. 78 // if visible.
79 void UpdateConnectionData(const std::string& service_path); 79 void UpdateConnectionData(const std::string& service_path);
(...skipping 18 matching lines...) Expand all
98 98
99 // Additional callbacks to set network state properties. 99 // Additional callbacks to set network state properties.
100 void SetServerHostnameCallback(const base::ListValue* args); 100 void SetServerHostnameCallback(const base::ListValue* args);
101 void SetPreferNetworkCallback(const base::ListValue* args); 101 void SetPreferNetworkCallback(const base::ListValue* args);
102 void SetAutoConnectCallback(const base::ListValue* args); 102 void SetAutoConnectCallback(const base::ListValue* args);
103 void SetIPConfigCallback(const base::ListValue* args); 103 void SetIPConfigCallback(const base::ListValue* args);
104 void SetIPConfigProperties(const base::ListValue* args, 104 void SetIPConfigProperties(const base::ListValue* args,
105 const std::string& service_path, 105 const std::string& service_path,
106 const base::DictionaryValue& shill_properties); 106 const base::DictionaryValue& shill_properties);
107 107
108 // Retrieves the properties for |service_path| and calls showDetailedInfo 108 // Retrieves the properties for |service_path| and calls sendNetworkDetails
109 // with the results. 109 // with the results.
110 void PopulateDictionaryDetailsCallback( 110 void PopulateDictionaryDetailsCallback(
111 const std::string& service_path, 111 const std::string& service_path,
112 const base::DictionaryValue& shill_properties); 112 const base::DictionaryValue& shill_properties);
113 113
114 // Gets the native window for hosting dialogs, etc. 114 // Gets the native window for hosting dialogs, etc.
115 gfx::NativeWindow GetNativeWindow() const; 115 gfx::NativeWindow GetNativeWindow() const;
116 116
117 // Gets the UI scale factor. 117 // Gets the UI scale factor.
118 float GetScaleFactor() const; 118 float GetScaleFactor() const;
119 119
120 // Gets the user PrefService associated with the WebUI. 120 // Gets the user PrefService associated with the WebUI.
121 const PrefService* GetPrefs() const; 121 const PrefService* GetPrefs() const;
122 122
123 // Handle various network commands and clicks on a network item 123 // Handle various network commands and clicks on a network item
124 // in the network list. 124 // in the network list.
125 // |args| must be { network_type, service_path, command } with 'command' 125 // |args| must be { network_type, service_path, command } with 'command'
126 // one of: [ add, forget, options, connect disconnect, activate ] 126 // one of: [ add, forget, options, connect disconnect, activate ]
127 void NetworkCommandCallback(const base::ListValue* args); 127 void NetworkCommandCallback(const base::ListValue* args);
128 128
129 // Helper functions called by NetworkCommandCallback(...) 129 // Helper functions called by NetworkCommandCallback(...)
130 void AddConnection(const std::string& type); 130 void AddConnection(const std::string& type);
131 void SendShowDetailedInfo(const std::string& service_path);
131 132
132 // Creates the map of wired networks. 133 // Creates the map of wired networks.
133 base::ListValue* GetWiredList(); 134 base::ListValue* GetWiredList();
134 135
135 // Creates the map of wireless networks. 136 // Creates the map of wireless networks.
136 base::ListValue* GetWirelessList(); 137 base::ListValue* GetWirelessList();
137 138
138 // Creates the map of virtual networks. 139 // Creates the map of virtual networks.
139 base::ListValue* GetVPNList(); 140 base::ListValue* GetVPNList();
140 141
(...skipping 11 matching lines...) Expand all
152 // of this object. 153 // of this object.
153 base::WeakPtrFactory<InternetOptionsHandler> weak_factory_; 154 base::WeakPtrFactory<InternetOptionsHandler> weak_factory_;
154 155
155 DISALLOW_COPY_AND_ASSIGN(InternetOptionsHandler); 156 DISALLOW_COPY_AND_ASSIGN(InternetOptionsHandler);
156 }; 157 };
157 158
158 } // namespace options 159 } // namespace options
159 } // namespace chromeos 160 } // namespace chromeos
160 161
161 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_INTERNET_OPTIONS_HANDLER_H_ 162 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_INTERNET_OPTIONS_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698