Changeset 79836 in webkit


Ignore:
Timestamp:
Feb 27, 2011 7:39:20 PM (13 years ago)
Author:
ojan@chromium.org
Message:

2011-02-25 Ojan Vafai <ojan@chromium.org>

Reviewed by Adam Barth.

[codereviewtool] fix expand links on git diffs
https://bugs.webkit.org/show_bug.cgi?id=55208

In git diffs, we don't have a "revision" span at the end
of each FileDiff.

  • code-review.js:
Location:
trunk/Websites/bugs.webkit.org
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Websites/bugs.webkit.org/ChangeLog

    r79515 r79836  
     12011-02-25  Ojan Vafai  <ojan@chromium.org>
     2
     3        Reviewed by Adam Barth.
     4
     5        [codereviewtool] fix expand links on git diffs
     6        https://bugs.webkit.org/show_bug.cgi?id=55208
     7
     8        In git diffs, we don't have a "revision" span at the end
     9        of each FileDiff.
     10        * code-review.js:
     11
    1122011-02-23  Ojan Vafai  <ojan@chromium.org>
    213
  • trunk/Websites/bugs.webkit.org/code-review.js

    r79399 r79836  
    647647    $('br', file_diff).replaceWith(expandBarHtml());
    648648
     649    // jquery doesn't support :last-of-type, so use querySelector instead.
    649650    var last_line = file_diff.querySelector('.LineContainer:last-of-type');
    650651    // Some patches for new files somehow end up with an empty context line at the end
    651652    // with a from line number of 0. Don't show expand links in that case either.
    652653    if (!$(last_line).hasClass('add') && !$(last_line).hasClass('remove') && fromLineNumber(last_line) != 0)
    653       $('.revision', file_diff).before(expandBarHtml(ABOVE));
     654      $(file_diff.querySelector('.DiffSection:last-of-type')).after(expandBarHtml(ABOVE));
    654655  }
    655656
Note: See TracChangeset for help on using the changeset viewer.