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

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

Issue 5094002: Fix favorite and auto_connect property usage (again) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix browsertest. Created 10 years, 1 month 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 #include "chrome/browser/chromeos/cros/network_library.h" 5 #include "chrome/browser/chromeos/cros/network_library.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 9
10 #include "app/l10n_util.h" 10 #include "app/l10n_util.h"
(...skipping 1359 matching lines...) Expand 10 before | Expand all | Expand 10 after
1370 } 1370 }
1371 1371
1372 // Create placeholder network for ethernet even if the service is not 1372 // Create placeholder network for ethernet even if the service is not
1373 // detected at this moment. 1373 // detected at this moment.
1374 if (!(*ethernet)) 1374 if (!(*ethernet))
1375 (*ethernet) = new EthernetNetwork(); 1375 (*ethernet) = new EthernetNetwork();
1376 1376
1377 DVLOG(1) << "Remembered networks:"; 1377 DVLOG(1) << "Remembered networks:";
1378 for (int i = 0; i < system->remembered_service_size; i++) { 1378 for (int i = 0; i < system->remembered_service_size; i++) {
1379 const ServiceInfo* service = system->GetRememberedServiceInfo(i); 1379 const ServiceInfo* service = system->GetRememberedServiceInfo(i);
1380 // Only services marked as auto_connect are considered remembered 1380 // Only services marked as favorite are considered remembered networks.
1381 // networks.
1382 // TODO(chocobo): Don't add to remembered service if currently available. 1381 // TODO(chocobo): Don't add to remembered service if currently available.
1383 if (service->auto_connect) { 1382 if (service->favorite) {
1384 DVLOG(1) << " (" << service->type << ") " << service->name 1383 DVLOG(1) << " (" << service->type << ") " << service->name
1385 << " mode=" << service->mode 1384 << " mode=" << service->mode
1386 << " sec=" << service->security 1385 << " sec=" << service->security
1387 << " pass=" << service->passphrase 1386 << " pass=" << service->passphrase
1388 << " id=" << service->identity 1387 << " id=" << service->identity
1389 << " certpath=" << service->cert_path 1388 << " certpath=" << service->cert_path
1389 << " fav=" << service->favorite
1390 << " auto=" << service->auto_connect; 1390 << " auto=" << service->auto_connect;
1391 if (service->type == TYPE_WIFI) { 1391 if (service->type == TYPE_WIFI) {
1392 remembered_wifi_networks->push_back(new WifiNetwork(service)); 1392 remembered_wifi_networks->push_back(new WifiNetwork(service));
1393 } 1393 }
1394 } 1394 }
1395 } 1395 }
1396 } 1396 }
1397 1397
1398 void Init() { 1398 void Init() {
1399 // First, get the currently available networks. This data is cached 1399 // First, get the currently available networks. This data is cached
(...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after
1849 return new NetworkLibraryStubImpl(); 1849 return new NetworkLibraryStubImpl();
1850 else 1850 else
1851 return new NetworkLibraryImpl(); 1851 return new NetworkLibraryImpl();
1852 } 1852 }
1853 1853
1854 } // namespace chromeos 1854 } // namespace chromeos
1855 1855
1856 // Allows InvokeLater without adding refcounting. This class is a Singleton and 1856 // Allows InvokeLater without adding refcounting. This class is a Singleton and
1857 // won't be deleted until it's last InvokeLater is run. 1857 // won't be deleted until it's last InvokeLater is run.
1858 DISABLE_RUNNABLE_METHOD_REFCOUNT(chromeos::NetworkLibraryImpl); 1858 DISABLE_RUNNABLE_METHOD_REFCOUNT(chromeos::NetworkLibraryImpl);
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/cros/network_library.h ('k') | chrome/browser/chromeos/dom_ui/internet_options_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698