Skip to content
Permalink
Browse files
2010-03-13 Ilya Tikhonovsky <loislo@chromium.org>
        Reviewed by Timothy Hatcher.

        WebInspector: Position of GraphBar elements is calculating more carefully
        and they fully visible at the bottom of Timeline panel.

        http://bugs.webkit.org/show_bug.cgi?id=35966

        * inspector/front-end/TimelinePanel.js:
        (WebInspector.TimelineRecordGraphRow.prototype.update):


Canonical link: https://commits.webkit.org/47286@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@55991 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
pavelfeldman committed Mar 15, 2010
1 parent d08ef96 commit 68e6d9b73b163fa831f27e7b7b17002942595150
Showing with 18 additions and 2 deletions.
  1. +12 −0 WebCore/ChangeLog
  2. +6 −2 WebCore/inspector/front-end/TimelinePanel.js
@@ -1,3 +1,15 @@
2010-03-13 Ilya Tikhonovsky <loislo@chromium.org>

Reviewed by Timothy Hatcher.

WebInspector: Position of GraphBar elements is calculating more carefully
and they fully visible at the bottom of Timeline panel.

http://bugs.webkit.org/show_bug.cgi?id=35966

* inspector/front-end/TimelinePanel.js:
(WebInspector.TimelineRecordGraphRow.prototype.update):

2010-03-15 MORITA Hajime <morrita@google.com>

Reviewed by Alexey Proskuryakov.
@@ -570,11 +570,15 @@ WebInspector.TimelineRecordGraphRow = function(graphContainer, scheduleRefresh,
WebInspector.TimelineRecordGraphRow.prototype = {
update: function(record, isEven, calculator, clientWidth, expandOffset, index)
{
const minWidth = 5;
const borderWidth = 4;
var workingArea = clientWidth - expandOffset - minWidth - borderWidth;
this._record = record;
this.element.className = "timeline-graph-side timeline-category-" + record.category.name + (isEven ? " even" : "");
var percentages = calculator.computeBarGraphPercentages(record);
var left = percentages.start / 100 * clientWidth;
var width = (percentages.end - percentages.start) / 100 * clientWidth;
var left = percentages.start / 100 * workingArea;
var width = (percentages.end - percentages.start) / 100 * workingArea;
width = width > minWidth ? width : minWidth;
this._barElement.style.left = (left + expandOffset) + "px";
this._barElement.style.width = width + "px";

0 comments on commit 68e6d9b

Please sign in to comment.