1. 25 Feb, 2015 2 commits
    • csillag's avatar
      Simply PDF text extraction · 27da8253
      csillag authored
      Removing some obsolete conditional code,
      which was necessary for some obsolete version
      of PDF.js.
      
      Fortunately, by now, all supported versions
      of PDF.js uses the same data format, so this
      workaround can go.
      27da8253
    • csillag's avatar
      Simply PDF text extraction · f42c3656
      csillag authored
      Earlier, on some versions of PDF.js, we used to
      use the PDF.js's FindController as a data source
      for the text extraction.
      
      However, at some point, we stopped using the
      routines shipped with it, since it didn't always
      provide use adequate spacing between the various
      pieces of texts. So we ended up just contenating
      the various pieces of text ourselves.
      
      Then, for new versions of PDF.js, we introduced
      other means of accessing the same information,
      completely bypassing the PDFFindController.
      
      This change simply unifies the access; now we can
      do the same an all PDF.js versions.
      f42c3656
  2. 24 Feb, 2015 2 commits
  3. 23 Feb, 2015 3 commits
  4. 22 Feb, 2015 3 commits
    • gergely-ujvari's avatar
      Merge pull request #1949 from hypothesis/1928-fix-realtime-delete · e009194e
      gergely-ujvari authored
      Fix real-time delete
      e009194e
    • csillag's avatar
      Adding tests for applyUpdate · 56de2455
      csillag authored
      56de2455
    • csillag's avatar
      Fix real-time delete · 5b488a77
      csillag authored
      When receiving a real-time notification about the removal
      of an annotation, we emit an annotationDeleted event,
      so that all components can react.
      
      Earlier, we emited this event simply with the Annotation
      bject that arrived on the wire.
      
      However, some components couldn't deal with this, because
      they were expecting to see the 'real' Annotation object,
      the ones they already knew about.
      
      So now we do a lookup before emiting the event, and use
      the locally found objects instead.
      5b488a77
  5. 20 Feb, 2015 6 commits
  6. 18 Feb, 2015 1 commit
    • csillag's avatar
      Change the scrolling API · 06152dca
      csillag authored
      The goal of this change is to avoid any false appearance
      that we are implementing the proposed scrollIntoView() API [1],
      while we clearly don't.
      
      So, changes:
      
       - Rename scrollIntoView to scrollToView
         on both Anchor and Highlight
       - Stop returning promises at both methods
      
      I also updated all the tests to reflect this change.
      
      [1] http://dev.w3.org/csswg/cssom-view/#dom-element-scrollintoview
      06152dca
  7. 17 Feb, 2015 1 commit
  8. 16 Feb, 2015 4 commits
  9. 14 Feb, 2015 2 commits
  10. 13 Feb, 2015 3 commits
  11. 12 Feb, 2015 3 commits
  12. 11 Feb, 2015 8 commits
  13. 10 Feb, 2015 2 commits
    • csillag's avatar
      Add/update test suite for scrolling · 745be4ef
      csillag authored
      745be4ef
    • csillag's avatar
      Refactor / fix scrolling. · 025cc7ea
      csillag authored
      EnhancedAnchoring plugin:
       - add `getAnchors()` method
       - add `scrollIntoView()` method
       - move some code from the bucket-bar
      
      TextHighlight plugin:
       - get rid of padded scrolling
       - scrollIntoView() no returns a promise
      
      Other:
       - When we click on an annotation card in the sidebar, we need to
         go to the anchor in the document. However, the highlight might
         not exist at this point, so we should look for the Anchor instead.
         So now we call `scrollIntoView()` onthe anchor.
       - The same goes when we click the arrows on the bucket bar
       - Rename `scrollTo` to `scrollIntoView` everywhere.
      025cc7ea