• Randall Leeds's avatar
    Big refactoring of anchor storage and flow · 67690048
    Randall Leeds authored
    In order to clean up vocabulary and better serve the needs of dynamic
    pages, refactor `setupAnnotation` to deal with re-setup, unhighlighting
    targets that have been removed from the annotation and re-anchoring
    anchors that have lost their ranges.
    
    - Store the Range on the anchor
    
      * The BucketBar would use it for getBoundingClientRect, except that
        it's a bit broken on Chrome.
    
      * The PDF Plugin can delete it to trigger re-anchoring no page load
    
    - Use MutationObservers in the PDF plugin and make smarter judgements
      about when pages are done rendering by using the renderState in
      addition to the text layer renderingDone flag.
    67690048
bucket-bar.coffee 9.33 KB