OS.js-extras icon indicating copy to clipboard operation
OS.js-extras copied to clipboard

pdfJS improvment

Open h4mit opened this issue 9 years ago • 4 comments

  • first page / last page buttons added
  • print button added
  • presentation mode button added
  • change page with mouse scroll wheel added
  • change page with input number

h4mit avatar Jul 18 '16 10:07 h4mit

Cool!

Just a few comments:

  • You can't use the id HTML property as this will not work when you have multiple similar windows open. The DOM spec only allows one unique ID. Use classNames instead, or like it was before the change: Create the element programatically.
  • There's a gui-canvas element you can use
  • There's also a gui-iframe element you can use
  • You left an extra whitespace in the first line of scheme.html

Also, in my next commit I'm adding a internal fullscreen API, so you don't have to use a third-party one when that is done :)

andersevenrud avatar Jul 18 '16 14:07 andersevenrud

https://os.js.org/doc/client/OSjs.API.html#.toggleFullscreen

:)

andersevenrud avatar Jul 18 '16 15:07 andersevenrud

Btw: You really should make a custom branch when making commits to official repositories. It's the only way to prevent problems if I decide to add something to your contribution.

andersevenrud avatar Jul 18 '16 15:07 andersevenrud

Also, you can use this to implement mousewheel now:

Utils.$bind(element, 'mousewheel', function(ev, pos) {

  console.log(pos.z); // '-1' or '1' depending on direction

});

andersevenrud avatar Jul 18 '16 21:07 andersevenrud