Improve the diff chunk selector.

Review Request #7454 — Created June 25, 2015 and submitted

Information

Review Board
release-2.5.x
63971d6...

Reviewers

The diff chunk selector is now cleaner, both visually and code-wise.

The big borders are gone. Instead, we have highlighting on the side,
which no longer has a "jumpy" effect like the borders have. They also
don't have the offset problems, nor do they cover up content.

The code is a bit cleaner. This class is no longer a singleton, and
instead is owned by the page. Recalculating the positions and sizes is
less expensive, and done as infrequently as possible.

The result is a lighter-weight, less noisy chunk selector.

Played around with the selector on different browsers. The results were
consistent.

Jumped all around the page, back-and-forth, with arrow keys and with clicking.

Tried zooming the page in/out, and resizing, while watching console.log
output. We calculated infrequently.


reviewbot
  1. Tool: Pyflakes
    Ignored Files:
        reviewboard/static/rb/js/pages/views/diffViewerPageView.js
        reviewboard/static/rb/js/diffviewer/views/chunkHighlighterView.js
        reviewboard/static/rb/css/pages/reviews.less
        reviewboard/static/rb/css/pages/diffviewer.less
    
    
    
    Tool: PEP8 Style Checker
    Ignored Files:
        reviewboard/static/rb/js/pages/views/diffViewerPageView.js
        reviewboard/static/rb/js/diffviewer/views/chunkHighlighterView.js
        reviewboard/static/rb/css/pages/reviews.less
        reviewboard/static/rb/css/pages/diffviewer.less
    
    
  2. 
      
david
  1. Great cleanup!

  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-2.5.x (4ede711)
Loading...