Fix a couple regressions in the new chunk highlighter.
Review Request #7460 — Created June 26, 2015 and submitted — Latest diff uploaded
The new chunk highlighter had two regressions. First, if the width of the page shrunk, there would be a horizontal scrollbar, due to the highlighter width not being reset to the natural width of the container. Second, the code assumed that there were chunks to display, but for loading diffs, this wouldn't be the case. We now check to make sure we can get the position of the chunk before doing any calculations based off of it, mirroring the logic we had before.
No longer hit JavaScript errors due to pending diff loads.
Resized the window back and forth, and saw that the highlighter width
was correct.