eight04 / image-picka

A Firefox/Chrome extension helping you download images.
MIT License
171 stars 19 forks source link

Drag-n-drop override option not working #321

Closed shape55 closed 1 year ago

shape55 commented 1 year ago

Hi, using Firefox 108.0.1, if I enable this checkbox I'm not seeing any difference in the file that is downloaded. It's still using Firefox's handler. To confirm it, I'm using this filename pattern: ${pageTitle} - ${name}${ext} and I have "Download with single click" enabled. If I use single click it saves a file with the specified pattern, but if I use DnD then it saves it using Firefox's default. This presents an issue with WebP images that Firefox cannot convert, so in this case I also get a saved file that has no image content.

Is the standard Image Picka DnD supposed to work if you drop the image into the same browser window? B/c this way it works whether I have the override option on or off.

Also, I’d recommend adding to your Add-on page that it also serves as a WebP converter b/c a lot of Firefox users are looking for this.

eight04 commented 1 year ago

Sorry for the confusion. That option actually means to override the default dragndrop handler of the website.

For example, when dragging images in Discord, it will try to upload/post the image. By enabling this option, the extension would take over the dragndrop handler.

Is the standard Image Picka DnD supposed to work if you drop the image into the same browser window? B/c this way it works whether I have the override option on or off.

Yes. According to the description, I guess you were trying to drag the image to desktop or other applications. This functionality is controlled by the browser and the extension can do nothing about it.

Therefore yes, Image Picka works and only works when you drop the image on the webpage.

Also, I’d recommend adding to your Add-on page that it also serves as a WebP converter b/c a lot of Firefox users are looking for this.

Image Picka doesn't modify the image but only downloads it.

shape55 commented 1 year ago

For example, when dragging images in Discord, it will try to upload/post the image. By enabling this option, the extension would take over the dragndrop handler.'

So you mean it overrides dragging to the website rather than from the website? I was trying only the latter.

Yes. According to the description, I guess you were trying to drag the image to desktop or other applications. This functionality is controlled by the browser and the extension can do nothing about it.

Ok, I figured it had to be this way but I actually didn't see it anywhere in the description. Could you please point me to that?

Image Picka doesn't modify the image but only downloads it.

Hmm, a lot of the images I downloaded though without using Image Picka would save incompatible WebP or Avif files with no content. Using IP those same images would save as compatible jpegs.

eight04 commented 1 year ago

So you mean it overrides dragging to the website rather than from the website? I was trying only the latter.

It is decided by where you drop the image.

If the image is dropped on the webpage, then the extension can catch the event and send that image to download manager.

If the image is dropped on the desktop, then only your desktop system can catch that event/information.

Ok, I figured it had to be this way but I actually didn't see it anywhere in the description. Could you please point me to that?

I meant according to your comment, I guess you were trying to drag the image to your desktop.