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

Side by Side Diff: chrome/browser/resources/net_internals/events_view.js

Issue 8474001: Add a timeline view to about:net-internals. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Update comments Created 9 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 /** 5 /**
6 * EventsView displays a filtered list of all events sharing a source, and 6 * EventsView displays a filtered list of all events sharing a source, and
7 * a details pane for the selected sources. 7 * a details pane for the selected sources.
8 * 8 *
9 * +----------------------++----------------+ 9 * +----------------------++----------------+
10 * | filter box || | 10 * | filter box || |
(...skipping 28 matching lines...) Expand all
39 assertFirstConstructorCall(EventsView); 39 assertFirstConstructorCall(EventsView);
40 40
41 // Call superclass's constructor. 41 // Call superclass's constructor.
42 superClass.call(this); 42 superClass.call(this);
43 43
44 // Initialize the sub-views. 44 // Initialize the sub-views.
45 var leftPane = new TopMidBottomView(new DivView(EventsView.TOPBAR_ID), 45 var leftPane = new TopMidBottomView(new DivView(EventsView.TOPBAR_ID),
46 new DivView(EventsView.MIDDLE_BOX_ID), 46 new DivView(EventsView.MIDDLE_BOX_ID),
47 new DivView(EventsView.BOTTOM_BAR_ID)); 47 new DivView(EventsView.BOTTOM_BAR_ID));
48 48
49 this.detailsView_ = new DetailsView(EventsView.TAB_HANDLES_CONTAINER_ID, 49 this.detailsView_ = new DetailsView(EventsView.DETAILS_LOG_BOX_ID);
50 EventsView.LOG_TAB_ID,
51 EventsView.TIMELINE_TAB_ID,
52 EventsView.DETAILS_LOG_BOX_ID,
53 EventsView.DETAILS_TIMELINE_BOX_ID);
54 50
55 this.splitterView_ = new ResizableVerticalSplitView( 51 this.splitterView_ = new ResizableVerticalSplitView(
56 leftPane, this.detailsView_, new DivView(EventsView.SIZER_ID)); 52 leftPane, this.detailsView_, new DivView(EventsView.SIZER_ID));
57 53
58 g_browser.sourceTracker.addObserver(this); 54 g_browser.sourceTracker.addSourceEntryObserver(this);
59 55
60 this.tableBody_ = $(EventsView.TBODY_ID); 56 this.tableBody_ = $(EventsView.TBODY_ID);
61 57
62 this.filterInput_ = $(EventsView.FILTER_INPUT_ID); 58 this.filterInput_ = $(EventsView.FILTER_INPUT_ID);
63 this.filterCount_ = $(EventsView.FILTER_COUNT_ID); 59 this.filterCount_ = $(EventsView.FILTER_COUNT_ID);
64 60
65 this.filterInput_.addEventListener('search', 61 this.filterInput_.addEventListener('search',
66 this.onFilterTextChanged_.bind(this), true); 62 this.onFilterTextChanged_.bind(this), true);
67 63
68 $(EventsView.DELETE_SELECTED_ID).onclick = this.deleteSelected_.bind(this); 64 $(EventsView.DELETE_SELECTED_ID).onclick = this.deleteSelected_.bind(this);
(...skipping 26 matching lines...) Expand all
95 // IDs for special HTML elements in events_view.html 91 // IDs for special HTML elements in events_view.html
96 EventsView.TBODY_ID = 'events-view-source-list-tbody'; 92 EventsView.TBODY_ID = 'events-view-source-list-tbody';
97 EventsView.FILTER_INPUT_ID = 'events-view-filter-input'; 93 EventsView.FILTER_INPUT_ID = 'events-view-filter-input';
98 EventsView.FILTER_COUNT_ID = 'events-view-filter-count'; 94 EventsView.FILTER_COUNT_ID = 'events-view-filter-count';
99 EventsView.DELETE_SELECTED_ID = 'events-view-delete-selected'; 95 EventsView.DELETE_SELECTED_ID = 'events-view-delete-selected';
100 EventsView.DELETE_ALL_ID = 'events-view-delete-all'; 96 EventsView.DELETE_ALL_ID = 'events-view-delete-all';
101 EventsView.SELECT_ALL_ID = 'events-view-select-all'; 97 EventsView.SELECT_ALL_ID = 'events-view-select-all';
102 EventsView.SORT_BY_ID_ID = 'events-view-sort-by-id'; 98 EventsView.SORT_BY_ID_ID = 'events-view-sort-by-id';
103 EventsView.SORT_BY_SOURCE_TYPE_ID = 'events-view-sort-by-source'; 99 EventsView.SORT_BY_SOURCE_TYPE_ID = 'events-view-sort-by-source';
104 EventsView.SORT_BY_DESCRIPTION_ID = 'events-view-sort-by-description'; 100 EventsView.SORT_BY_DESCRIPTION_ID = 'events-view-sort-by-description';
105 EventsView.TAB_HANDLES_CONTAINER_ID = 'events-view-details-tab-handles';
106 EventsView.LOG_TAB_ID = 'events-view-details-log-tab';
107 EventsView.TIMELINE_TAB_ID = 'events-view-details-timeline-tab';
108 EventsView.DETAILS_LOG_BOX_ID = 'events-view-details-log-box'; 101 EventsView.DETAILS_LOG_BOX_ID = 'events-view-details-log-box';
109 EventsView.DETAILS_TIMELINE_BOX_ID = 'events-view-details-timeline-box';
110 EventsView.TOPBAR_ID = 'events-view-filter-box'; 102 EventsView.TOPBAR_ID = 'events-view-filter-box';
111 EventsView.MIDDLE_BOX_ID = 'events-view-source-list'; 103 EventsView.MIDDLE_BOX_ID = 'events-view-source-list';
112 EventsView.BOTTOM_BAR_ID = 'events-view-action-box'; 104 EventsView.BOTTOM_BAR_ID = 'events-view-action-box';
113 EventsView.SIZER_ID = 'events-view-splitter-box'; 105 EventsView.SIZER_ID = 'events-view-splitter-box';
114 106
115 cr.addSingletonGetter(EventsView); 107 cr.addSingletonGetter(EventsView);
116 108
117 EventsView.prototype = { 109 EventsView.prototype = {
118 // Inherit the superclass's methods. 110 // Inherit the superclass's methods.
119 __proto__: superClass.prototype, 111 __proto__: superClass.prototype,
(...skipping 573 matching lines...) Expand 10 before | Expand all | Expand 10 after
693 var source1Text = source1.getSourceTypeString(); 685 var source1Text = source1.getSourceTypeString();
694 var source2Text = source2.getSourceTypeString(); 686 var source2Text = source2.getSourceTypeString();
695 var compareResult = source1Text.localeCompare(source2Text); 687 var compareResult = source1Text.localeCompare(source2Text);
696 if (compareResult != 0) 688 if (compareResult != 0)
697 return compareResult; 689 return compareResult;
698 return compareSourceId(source1, source2); 690 return compareSourceId(source1, source2);
699 } 691 }
700 692
701 return EventsView; 693 return EventsView;
702 })(); 694 })();
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698