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

Unified Diff: netlog_viewer/quic_view.js

Issue 2162963002: [polymer] Merge of master into polymer10-migration (Closed) Base URL: git@github.com:catapult-project/catapult.git@polymer10-migration
Patch Set: Merge polymer10-migration int polymer10-merge Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « netlog_viewer/quic_view.html ('k') | netlog_viewer/resizable_vertical_split_view.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: netlog_viewer/quic_view.js
diff --git a/netlog_viewer/quic_view.js b/netlog_viewer/quic_view.js
new file mode 100644
index 0000000000000000000000000000000000000000..4eba9f21bfc6509b47e21e420dbed001a8d9dc61
--- /dev/null
+++ b/netlog_viewer/quic_view.js
@@ -0,0 +1,60 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+/**
+ * This view displays a summary of the state of each QUIC session, and
+ * has links to display them in the events tab.
+ */
+var QuicView = (function() {
+ 'use strict';
+
+ // We inherit from DivView.
+ var superClass = DivView;
+
+ /**
+ * @constructor
+ */
+ function QuicView() {
+ assertFirstConstructorCall(QuicView);
+
+ // Call superclass's constructor.
+ superClass.call(this, QuicView.MAIN_BOX_ID);
+
+ g_browser.addQuicInfoObserver(this, true);
+ }
+
+ QuicView.TAB_ID = 'tab-handle-quic';
+ QuicView.TAB_NAME = 'QUIC';
+ QuicView.TAB_HASH = '#quic';
+
+ // IDs for special HTML elements in quic_view.html
+ QuicView.MAIN_BOX_ID = 'quic-view-tab-content';
+
+ cr.addSingletonGetter(QuicView);
+
+ QuicView.prototype = {
+ // Inherit the superclass's methods.
+ __proto__: superClass.prototype,
+
+ onLoadLogFinish: function(data) {
+ return this.onQuicInfoChanged(data.quicInfo);
+ },
+
+ /**
+ * If there are any sessions, display a single table with
+ * information on each QUIC session. Otherwise, displays "None".
+ */
+ onQuicInfoChanged: function(quicInfo) {
+ if (!quicInfo)
+ return false;
+ // TODO(rayraymond): Update DOM without use of jstemplate.
+ // var input = new JsEvalContext(quicInfo);
+ // jstProcess(input, $(QuicView.MAIN_BOX_ID));
+ return true;
+ },
+ };
+
+ return QuicView;
+})();
+
« no previous file with comments | « netlog_viewer/quic_view.html ('k') | netlog_viewer/resizable_vertical_split_view.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698