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

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

Issue 6025017: Adds the ability to load JSON log files to about:net-internals. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Put load log button on its own line Created 9 years, 11 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 457 matching lines...) Expand 10 before | Expand all | Expand 10 after
468 entry.remove(); 468 entry.remove();
469 delete this.sourceIdToEntryMap_[id]; 469 delete this.sourceIdToEntryMap_[id];
470 this.incrementPrefilterCount(-1); 470 this.incrementPrefilterCount(-1);
471 } 471 }
472 } 472 }
473 }; 473 };
474 474
475 /** 475 /**
476 * Called whenever all log events are deleted. 476 * Called whenever all log events are deleted.
477 */ 477 */
478 EventsView.prototype.onAllLogEntriesDeleted = function(offset) { 478 EventsView.prototype.onAllLogEntriesDeleted = function() {
479 this.initializeSourceList_(); 479 this.initializeSourceList_();
480 }; 480 };
481 481
482 /**
483 * Called when either a log file is loaded or when going back to actively
484 * logging events. In either case, called after clearing the old entries,
485 * but before getting any new ones.
486 */
487 EventsView.prototype.onSetIsViewingLogFile = function(isViewingLogFile) {
488 // Needed to sort new sourceless entries correctly.
489 this.maxReceivedSourceId_ = 0;
490 };
491
482 EventsView.prototype.incrementPrefilterCount = function(offset) { 492 EventsView.prototype.incrementPrefilterCount = function(offset) {
483 this.numPrefilter_ += offset; 493 this.numPrefilter_ += offset;
484 this.invalidateFilterCounter_(); 494 this.invalidateFilterCounter_();
485 }; 495 };
486 496
487 EventsView.prototype.incrementPostfilterCount = function(offset) { 497 EventsView.prototype.incrementPostfilterCount = function(offset) {
488 this.numPostfilter_ += offset; 498 this.numPostfilter_ += offset;
489 this.invalidateFilterCounter_(); 499 this.invalidateFilterCounter_();
490 }; 500 };
491 501
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
604 EventsView.REPAINT_FILTER_COUNTER_TIMEOUT_MS); 614 EventsView.REPAINT_FILTER_COUNTER_TIMEOUT_MS);
605 } 615 }
606 }; 616 };
607 617
608 EventsView.prototype.repaintFilterCounter_ = function() { 618 EventsView.prototype.repaintFilterCounter_ = function() {
609 this.outstandingRepaintFilterCounter_ = false; 619 this.outstandingRepaintFilterCounter_ = false;
610 this.filterCount_.innerHTML = ''; 620 this.filterCount_.innerHTML = '';
611 addTextNode(this.filterCount_, 621 addTextNode(this.filterCount_,
612 this.numPostfilter_ + ' of ' + this.numPrefilter_); 622 this.numPostfilter_ + ' of ' + this.numPrefilter_);
613 }; 623 };
OLDNEW
« no previous file with comments | « chrome/browser/resources/net_internals/dataview.js ('k') | chrome/browser/resources/net_internals/index.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698