|
Massively simplify the NetworkChangeNotifier infrastructure:
* Use a process-wide object (singleton pattern)
* Create/destroy this object on the main thread, make it outlive all consumers
* Make observer-related functions threadsafe
As a result, the notifier can now be used by any thread (eliminating things like NetworkChangeObserverProxy and NetworkChangeNotifierProxy, and expanding its usefulness); its creation and inner workings are much simplified (eliminating implementation-specific classes); and it is simpler to access (eliminating things like NetworkChangeNotifierThread and a LOT of passing pointers around).
BUG=none
TEST=Unittests; network changes still trigger notifications
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=50895
Total comments: 59
Total comments: 33
Total comments: 18
Total comments: 12
Total comments: 9
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+613 lines, -2822 lines) |
Patch |
 |
M |
base/observer_list_threadsafe.h
|
View
|
4
5
6
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
chrome/browser/browser_main.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+3 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/io_thread.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+0 lines, -2 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/io_thread.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+3 lines, -9 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/net/chrome_url_request_context.cc
|
View
|
1
2
3
4
5
6
|
6 chunks |
+10 lines, -17 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/net/connection_tester.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+8 lines, -14 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/net/resolve_proxy_msg_helper_unittest.cc
|
View
|
1
2
3
4
5
6
|
4 chunks |
+4 lines, -4 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/profile.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+0 lines, -7 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/profile.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+1 line, -6 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/engine/syncapi.h
|
View
|
1
2
3
4
5
6
|
4 chunks |
+1 line, -10 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/engine/syncapi.cc
|
View
|
1
2
3
4
5
6
|
9 chunks |
+12 lines, -34 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/glue/sync_backend_host.h
|
View
|
1
2
3
4
5
6
|
9 chunks |
+4 lines, -24 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/glue/sync_backend_host.cc
|
View
|
1
2
3
4
5
6
|
4 chunks |
+1 line, -5 lines |
0 comments
|
Download
|
 |
D |
chrome/browser/sync/net/network_change_notifier_io_thread.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -38 lines |
0 comments
|
Download
|
 |
D |
chrome/browser/sync/net/network_change_notifier_io_thread.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -24 lines |
0 comments
|
Download
|
 |
D |
chrome/browser/sync/net/network_change_notifier_io_thread_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -80 lines |
0 comments
|
Download
|
 |
MM |
chrome/browser/sync/notifier/server_notifier_thread.h
|
View
|
3
4
5
6
|
2 chunks |
+1 line, -7 lines |
0 comments
|
Download
|
 |
MM |
chrome/browser/sync/notifier/server_notifier_thread.cc
|
View
|
3
4
5
6
|
1 chunk |
+1 line, -4 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/profile_sync_factory_impl.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+1 line, -11 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/profile_sync_factory_impl.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+4 lines, -12 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/profile_sync_factory_impl_unittest.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+1 line, -6 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/profile_sync_service.h
|
View
|
1
2
3
4
5
6
|
4 chunks |
+1 line, -10 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/profile_sync_service.cc
|
View
|
1
2
3
4
5
6
|
5 chunks |
+4 lines, -11 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/sync_setup_wizard_unittest.cc
|
View
|
1
2
3
4
5
6
|
4 chunks |
+2 lines, -8 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/sync/test_profile_sync_service.h
|
View
|
1
2
3
4
5
6
|
3 chunks |
+4 lines, -19 lines |
0 comments
|
Download
|
 |
M |
chrome/chrome.gyp
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -2 lines |
0 comments
|
Download
|
 |
M |
chrome/chrome_browser.gypi
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -2 lines |
0 comments
|
Download
|
 |
M |
chrome/chrome_common.gypi
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -5 lines |
0 comments
|
Download
|
 |
M |
chrome/chrome_tests.gypi
|
View
|
1
2
3
4
5
6
|
7 chunks |
+0 lines, -58 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/fake_network_change_notifier_thread.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -67 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/fake_network_change_notifier_thread.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -77 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/fake_network_change_notifier_thread_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -164 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/mock_network_change_observer.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -32 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/network_change_notifier_proxy.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -70 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/network_change_notifier_proxy.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -55 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/network_change_notifier_proxy_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -101 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/network_change_notifier_thread.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -37 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/network_change_observer_proxy.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -114 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/network_change_observer_proxy.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -137 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/network_change_observer_proxy_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -230 lines |
0 comments
|
Download
|
 |
M |
chrome/common/net/notifier/communicator/login.h
|
View
|
1
2
3
4
5
6
|
3 chunks |
+1 line, -3 lines |
0 comments
|
Download
|
 |
M |
chrome/common/net/notifier/communicator/login.cc
|
View
|
1
2
3
4
5
6
|
6 chunks |
+3 lines, -7 lines |
0 comments
|
Download
|
 |
M |
chrome/common/net/notifier/listener/mediator_thread_impl.h
|
View
|
1
2
3
4
5
6
|
4 chunks |
+2 lines, -12 lines |
0 comments
|
Download
|
 |
M |
chrome/common/net/notifier/listener/mediator_thread_impl.cc
|
View
|
1
2
3
4
5
6
|
7 chunks |
+3 lines, -15 lines |
0 comments
|
Download
|
 |
M |
chrome/common/net/notifier/listener/talk_mediator_unittest.cc
|
View
|
1
2
3
4
5
6
|
4 chunks |
+3 lines, -7 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/thread_blocker.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -51 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/thread_blocker.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -47 lines |
0 comments
|
Download
|
 |
D |
chrome/common/net/thread_blocker_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -109 lines |
0 comments
|
Download
|
 |
M |
chrome/service/cloud_print/cloud_print_proxy_backend.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+2 lines, -4 lines |
0 comments
|
Download
|
 |
D |
chrome/service/net/service_network_change_notifier_thread.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -50 lines |
0 comments
|
Download
|
 |
D |
chrome/service/net/service_network_change_notifier_thread.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -46 lines |
0 comments
|
Download
|
 |
D |
chrome/service/net/service_network_change_notifier_thread_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -100 lines |
0 comments
|
Download
|
 |
M |
chrome/service/net/service_url_request_context.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+4 lines, -4 lines |
0 comments
|
Download
|
 |
M |
chrome/service/service_process.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+4 lines, -6 lines |
0 comments
|
Download
|
 |
M |
chrome/service/service_process.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+5 lines, -5 lines |
0 comments
|
Download
|
 |
M |
chrome_frame/test/test_server_test.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+5 lines, -10 lines |
0 comments
|
Download
|
 |
M |
net/base/host_resolver.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+1 line, -5 lines |
0 comments
|
Download
|
 |
M |
net/base/host_resolver_impl.h
|
View
|
1
2
3
4
5
6
|
3 chunks |
+1 line, -6 lines |
0 comments
|
Download
|
 |
M |
net/base/host_resolver_impl.cc
|
View
|
1
2
3
4
5
6
|
6 chunks |
+5 lines, -11 lines |
0 comments
|
Download
|
 |
M |
net/base/host_resolver_impl_unittest.cc
|
View
|
1
2
3
4
5
6
7
|
11 chunks |
+15 lines, -28 lines |
0 comments
|
Download
|
 |
M |
net/base/mock_host_resolver.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
D |
net/base/mock_network_change_notifier.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -46 lines |
0 comments
|
Download
|
 |
M |
net/base/net_test_suite.h
|
View
|
1
2
3
4
5
6
|
3 chunks |
+4 lines, -1 line |
0 comments
|
Download
|
 |
M |
net/base/network_change_notifier.h
|
View
|
1
2
3
4
5
6
7
|
2 chunks |
+53 lines, -12 lines |
2 comments
|
Download
|
 |
M |
net/base/network_change_notifier.cc
|
View
|
1
2
3
4
5
6
7
|
3 chunks |
+40 lines, -4 lines |
0 comments
|
Download
|
 |
M |
net/base/network_change_notifier_linux.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+21 lines, -33 lines |
7 comments
|
Download
|
 |
M |
net/base/network_change_notifier_linux.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+63 lines, -67 lines |
0 comments
|
Download
|
 |
M |
net/base/network_change_notifier_mac.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+27 lines, -29 lines |
0 comments
|
Download
|
 |
M |
net/base/network_change_notifier_mac.cc
|
View
|
1
2
3
4
5
6
7
|
2 chunks |
+74 lines, -213 lines |
0 comments
|
Download
|
 |
M |
net/base/network_change_notifier_win.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+11 lines, -17 lines |
0 comments
|
Download
|
 |
M |
net/base/network_change_notifier_win.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+12 lines, -61 lines |
0 comments
|
Download
|
 |
M |
net/http/http_cache.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+2 lines, -3 lines |
0 comments
|
Download
|
 |
M |
net/http/http_cache.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+4 lines, -7 lines |
0 comments
|
Download
|
 |
M |
net/http/http_network_layer.h
|
View
|
1
2
3
4
5
6
|
4 chunks |
+4 lines, -8 lines |
0 comments
|
Download
|
 |
M |
net/http/http_network_layer.cc
|
View
|
1
2
3
4
5
6
|
6 chunks |
+3 lines, -12 lines |
0 comments
|
Download
|
 |
M |
net/http/http_network_layer_unittest.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+9 lines, -11 lines |
0 comments
|
Download
|
 |
M |
net/http/http_network_session.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+0 lines, -3 lines |
0 comments
|
Download
|
 |
M |
net/http/http_network_session.cc
|
View
|
1
2
3
4
5
6
|
4 chunks |
+16 lines, -29 lines |
0 comments
|
Download
|
 |
M |
net/http/http_network_transaction_unittest.cc
|
View
|
1
2
3
4
5
6
|
5 chunks |
+8 lines, -10 lines |
0 comments
|
Download
|
 |
M |
net/net.gyp
|
View
|
1
2
3
4
5
6
|
2 chunks |
+1 line, -6 lines |
0 comments
|
Download
|
 |
M |
net/proxy/proxy_script_fetcher_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+5 lines, -7 lines |
0 comments
|
Download
|
 |
M |
net/proxy/proxy_service.h
|
View
|
1
2
3
4
5
6
|
7 chunks |
+10 lines, -16 lines |
0 comments
|
Download
|
 |
M |
net/proxy/proxy_service.cc
|
View
|
1
2
3
4
5
6
|
8 chunks |
+8 lines, -21 lines |
0 comments
|
Download
|
 |
M |
net/proxy/proxy_service_unittest.cc
|
View
|
1
2
3
4
5
6
7
|
36 chunks |
+36 lines, -50 lines |
0 comments
|
Download
|
 |
M |
net/socket/client_socket_pool_base.h
|
View
|
1
2
3
4
5
6
|
4 chunks |
+4 lines, -9 lines |
0 comments
|
Download
|
 |
M |
net/socket/client_socket_pool_base.cc
|
View
|
1
2
3
4
5
6
|
5 chunks |
+9 lines, -9 lines |
0 comments
|
Download
|
 |
M |
net/socket/client_socket_pool_base_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
net/socket/socks_client_socket_pool.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
 |
M |
net/socket/socks_client_socket_pool.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+2 lines, -3 lines |
0 comments
|
Download
|
 |
M |
net/socket/socks_client_socket_pool_unittest.cc
|
View
|
1
2
3
4
5
6
|
4 chunks |
+10 lines, -15 lines |
0 comments
|
Download
|
 |
M |
net/socket/ssl_client_socket_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
net/socket/ssl_test_util.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+2 lines, -3 lines |
0 comments
|
Download
|
 |
M |
net/socket/tcp_client_socket_pool.h
|
View
|
1
2
3
4
5
6
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
 |
M |
net/socket/tcp_client_socket_pool.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -3 lines |
0 comments
|
Download
|
 |
M |
net/socket/tcp_client_socket_pool_unittest.cc
|
View
|
1
2
3
4
5
6
7
|
5 chunks |
+5 lines, -11 lines |
0 comments
|
Download
|
 |
M |
net/socket/tcp_client_socket_unittest.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
net/socket/tcp_pinger_unittest.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+3 lines, -5 lines |
0 comments
|
Download
|
 |
M |
net/spdy/spdy_http_stream_unittest.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+3 lines, -4 lines |
0 comments
|
Download
|
 |
M |
net/spdy/spdy_network_transaction_unittest.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+3 lines, -4 lines |
0 comments
|
Download
|
 |
M |
net/spdy/spdy_session_pool.h
|
View
|
1
2
3
4
5
6
|
5 chunks |
+3 lines, -6 lines |
0 comments
|
Download
|
 |
M |
net/spdy/spdy_session_pool.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+8 lines, -7 lines |
0 comments
|
Download
|
 |
M |
net/spdy/spdy_session_unittest.cc
|
View
|
1
2
3
4
5
6
|
3 chunks |
+3 lines, -4 lines |
0 comments
|
Download
|
 |
M |
net/tools/fetch/fetch_client.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+6 lines, -10 lines |
0 comments
|
Download
|
 |
M |
net/tools/hresolv/hresolv.cc
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
net/url_request/url_request_unittest.h
|
View
|
1
2
3
4
5
6
|
2 chunks |
+10 lines, -11 lines |
0 comments
|
Download
|
 |
M |
webkit/tools/test_shell/test_shell_request_context.cc
|
View
|
1
2
3
4
5
6
|
2 chunks |
+4 lines, -5 lines |
0 comments
|
Download
|
Total messages: 26 (0 generated)
|