results.webkit.org: Use canvas for timeline
authorjbedard@apple.com <jbedard@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 8 Aug 2019 17:53:51 +0000 (17:53 +0000)
committerjbedard@apple.com <jbedard@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 8 Aug 2019 17:53:51 +0000 (17:53 +0000)
commit354e44ee7c948aee580ee31fc2ffade1ac4c2b06
treef7cedb0477a84dc4fbe9b636b97dc2c1f860b4b5
parent8c2623fc97b599d6fd7c76eadf383297e3788bb4
results.webkit.org: Use canvas for timeline
https://bugs.webkit.org/show_bug.cgi?id=200172

Rubber-stamped by Aakash Jain.

* resultsdbpy/resultsdbpy/view/static/js/commit.js:
(Commit.constructor): Make uuid a member variable instead of a member function for efficiency.
(Commit.compare): Ditto.
(_CommitBank.commitByUuid): Ditto.
(_CommitBank._loadSiblings): Ditto.
(_CommitBank._load): Ditto.
* resultsdbpy/resultsdbpy/view/static/js/timeline.js:
(tickForCommit): Deleted.
(minimumUuidForResults): Given a dictionary of result lists, determine the minimum UUID
which encompasses all results. Crucially, this function must exclude an UUIDs which may
refer to results excluded because of the limit argument.
(renderTimeline): Deleted.
(commitsForResults): Given a dictionary of result lists, return a list of commits associated
with those results.
(scaleForCommits): Given a list of commits, generate a scale to be consumed by the canvas Timeline.
(repositoriesForCommits): Given a list of commits, return a sorted list of associated repository ids.
(xAxisFromScale): Create a canvas-based x-axis based on the provided scale and a repository id.
(inPlaceCombine): Combine result objects together.
(statsForSingleResult): Turn a single result into a stat object.
(combineResults): Given lists of results, combine these lists while keeping the original lists unchanged.
(Dot): Deleted.
(TimelineFromEndpoint): Renamed from Timeline.
(TimelineFromEndpoint.constructor): Canvas Timeline manages expansion and collapsing of nested timelines.
(TimelineFromEndpoint.teardown): Detach callbacks from CommitBank.
(TimelineFromEndpoint.update): Update with any new commit information, force a re-draw of the current
cache contents.
(TimelineFromEndpoint.reload): Remove management of nested timelines.
(TimelineFromEndpoint.render): Use canvas Timeline instead of html timeline to visualize results.
* resultsdbpy/resultsdbpy/view/templates/search.html: Use TimelineFromEndpoint class.
* resultsdbpy/resultsdbpy/view/templates/suite_results.html: Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248425 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Tools/ChangeLog
Tools/resultsdbpy/resultsdbpy/view/static/js/commit.js
Tools/resultsdbpy/resultsdbpy/view/static/js/timeline.js
Tools/resultsdbpy/resultsdbpy/view/templates/search.html
Tools/resultsdbpy/resultsdbpy/view/templates/suite_results.html