dandelion icon indicating copy to clipboard operation
dandelion copied to clipboard

[META] Image viewing and saving - nonAPI

Open gsantner opened this issue 9 years ago • 13 comments

General information

  • App version: 0.2.1

  • [ ] Save images

    • [ ] use correct extensions (jpg, png, gif)
    • [x] make sure parents exist #137
    • [x] make sure write permission given
  • [ ] Picture ContextMenu improvements

  • [ ] Optional: Lightweight picture viewer (jpg, png, gif)

    • [ ] Very optional: Swipe pictures of post if there are multiple

Correctly save images

Currently everything is saved as *.png file when clicking picture -> Context menu -> save. The images should be saved with the proper extension (jpg/png/gif/..)

Picture ContextMenu improvements

Currently

  1. Long-Click on Picture in WebView
  2. Context menu gets opened

Expected

  • Download picture -> Notification which opens the system picture viewer with the picture
  • Show picture (New): Some kind of dialog or popup, which just shows the picture, but leaves WebView as it is
  • Allow to copy url of image (#136) - just like normal links, code exists
  • Allow different file formats: jpg, png, gif

gsantner avatar Nov 04 '16 02:11 gsantner

I guess some "show image" feature will be/is implemented in the mobile site?

Edit: Displaying a notification after download finished is a great Idea! For "Show Image": We could take a look at https://github.com/davemorrissey/subsampling-scale-image-view Different file formats: Related to #102

vanitasvitae avatar Nov 04 '16 21:11 vanitasvitae

Show image is one of my use cases: I spend the most time on diaspora looking on pictures. Sometimes there are really good pictures, but I can't really see anything. So an built-in context action for viewing (and allowing zoom-in) would be great.

Library: Don't know how big the mentioned one is, but I think some lightweight (without much options) is enough. But it should handle the most common (mentioned above) file extensions.

gsantner avatar Nov 05 '16 14:11 gsantner

The library I mentioned handles images, gifts and I think even webms.

It would be nice, if the imageViewer would offer swipe actions that allow to go to the next/previous image in the post (if there is one). I don't know, how hard that would be to accomplish without the API though.

vanitasvitae avatar Nov 05 '16 15:11 vanitasvitae

Any contributions are appreciated on this issue!

gsantner avatar Dec 25 '16 00:12 gsantner

Just came across this which could help to implement the "Copy link to clipboard": http://cketti.de/2016/06/15/share-url-to-clipboard/

noplanman avatar Dec 30 '16 10:12 noplanman

@noplanman: copying the image link to clipboard is no big deal, there is no extra app needed for that, but thank you anyway :)

vanitasvitae avatar Dec 30 '16 14:12 vanitasvitae

Oh, I didn't post it for the extra app, but for the part "Option 3: Extend the Share dialog". As for now, there is no such option on the share dialog, meaning I need to select "Open in external browser", then copy the URL from there.

noplanman avatar Dec 30 '16 14:12 noplanman

Yeah, I meant, adding such an option to the share menu is no big deal ;)

vanitasvitae avatar Dec 30 '16 14:12 vanitasvitae

Aaaah, great! 😃

noplanman avatar Dec 30 '16 14:12 noplanman

I just added an option to copy image urls to clipboard :)

vanitasvitae avatar Dec 30 '16 21:12 vanitasvitae

@vanitasvitae Nice :D We could also inherit&override from the ContextMenu of normal links (don't know how you did :) )

gsantner avatar Dec 30 '16 21:12 gsantner

Its only ~5 Lines of code. I don't think its worth to inherit something there ;) Edit: I just added another switch case without body right before the copy link case. Thats about it. So in fact, it actually uses the copy text code.

vanitasvitae avatar Dec 30 '16 21:12 vanitasvitae

I just added an option to copy image urls to clipboard :)

Thanks! I use this so much... Can't wait for the next version 😇

noplanman avatar Dec 30 '16 21:12 noplanman