Index: chrome/browser/resources/net_internals/browser_bridge.js |
diff --git a/chrome/browser/resources/net_internals/browser_bridge.js b/chrome/browser/resources/net_internals/browser_bridge.js |
index e5a19bf4ce4a360ea181ff2f6c45f5c20d70f796..a49f55bf4fac677260ab4f73ac1da5d89f481039 100644 |
--- a/chrome/browser/resources/net_internals/browser_bridge.js |
+++ b/chrome/browser/resources/net_internals/browser_bridge.js |
@@ -67,6 +67,9 @@ var BrowserBridge = (function() { |
new PollableDataHelper('onSpdyAlternateProtocolMappingsChanged', |
this.sendGetSpdyAlternateProtocolMappings.bind( |
this)); |
+ this.pollableDataHelpers_.sdchInfo = |
+ new PollableDataHelper('onSdchInfoChanged', |
+ this.sendGetSdchInfo.bind(this)); |
if (cr.isWindows) { |
this.pollableDataHelpers_.serviceProviders = |
new PollableDataHelper('onServiceProvidersChanged', |
@@ -246,6 +249,10 @@ var BrowserBridge = (function() { |
this.send('getExtensionInfo'); |
}, |
+ sendGetSdchInfo: function() { |
+ this.send('getSdchInfo'); |
+ }, |
+ |
enableIPv6: function() { |
this.send('enableIPv6'); |
}, |
@@ -419,6 +426,10 @@ var BrowserBridge = (function() { |
this.pollableDataHelpers_.systemLog.update(systemLog); |
}, |
+ receivedSdchInfo: function(sdchInfo) { |
+ this.pollableDataHelpers_.sdchInfo.update(sdchInfo); |
+ }, |
+ |
//-------------------------------------------------------------------------- |
/** |
@@ -693,6 +704,17 @@ var BrowserBridge = (function() { |
}, |
/** |
+ * Adds a listener of SDCH information. |observer| will be called |
+ * back when data is received, through: |
+ * |
+ * observer.onSdchInfoChanged(sdchInfo) |
+ */ |
+ addSdchInfoObserver: function(observer, ignoreWhenUnchanged) { |
+ this.pollableDataHelpers_.sdchInfo.addObserver( |
+ observer, ignoreWhenUnchanged); |
+ }, |
+ |
+ /** |
* If |force| is true, calls all startUpdate functions. Otherwise, just |
* runs updates with active observers. |
*/ |