| OLD | NEW |
| 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 #include "net/proxy/proxy_config_service_android.h" | 5 #include "net/proxy/proxy_config_service_android.h" |
| 6 | 6 |
| 7 #include <sys/system_properties.h> | 7 #include <sys/system_properties.h> |
| 8 | 8 |
| 9 #include "base/android/jni_string.h" | 9 #include "base/android/jni_string.h" |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 #include "googleurl/src/url_parse.h" | 21 #include "googleurl/src/url_parse.h" |
| 22 #include "jni/ProxyChangeListener_jni.h" | 22 #include "jni/ProxyChangeListener_jni.h" |
| 23 #include "net/base/host_port_pair.h" | 23 #include "net/base/host_port_pair.h" |
| 24 #include "net/proxy/proxy_config.h" | 24 #include "net/proxy/proxy_config.h" |
| 25 | 25 |
| 26 using base::android::AttachCurrentThread; | 26 using base::android::AttachCurrentThread; |
| 27 using base::android::ConvertUTF8ToJavaString; | 27 using base::android::ConvertUTF8ToJavaString; |
| 28 using base::android::ConvertJavaStringToUTF8; | 28 using base::android::ConvertJavaStringToUTF8; |
| 29 using base::android::CheckException; | 29 using base::android::CheckException; |
| 30 using base::android::ClearException; | 30 using base::android::ClearException; |
| 31 using base::android::GetMethodID; | |
| 32 using base::android::ScopedJavaGlobalRef; | 31 using base::android::ScopedJavaGlobalRef; |
| 33 | 32 |
| 34 namespace net { | 33 namespace net { |
| 35 | 34 |
| 36 namespace { | 35 namespace { |
| 37 | 36 |
| 38 typedef ProxyConfigServiceAndroid::GetPropertyCallback GetPropertyCallback; | 37 typedef ProxyConfigServiceAndroid::GetPropertyCallback GetPropertyCallback; |
| 39 | 38 |
| 40 // Returns whether the provided string was successfully converted to a port. | 39 // Returns whether the provided string was successfully converted to a port. |
| 41 bool ConvertStringToPort(const std::string& port, int* output) { | 40 bool ConvertStringToPort(const std::string& port, int* output) { |
| (...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 325 : delegate_(new Delegate( | 324 : delegate_(new Delegate( |
| 326 network_task_runner, jni_task_runner, get_property_callback)) { | 325 network_task_runner, jni_task_runner, get_property_callback)) { |
| 327 delegate_->FetchInitialConfig(); | 326 delegate_->FetchInitialConfig(); |
| 328 } | 327 } |
| 329 | 328 |
| 330 void ProxyConfigServiceAndroid::ProxySettingsChanged() { | 329 void ProxyConfigServiceAndroid::ProxySettingsChanged() { |
| 331 delegate_->ProxySettingsChanged(); | 330 delegate_->ProxySettingsChanged(); |
| 332 } | 331 } |
| 333 | 332 |
| 334 } // namespace net | 333 } // namespace net |
| OLD | NEW |