Coder Social home page Coder Social logo

Comments (5)

Infocatcher avatar Infocatcher commented on July 19, 2024

Added ability to remove downloads from history using middle-click in panel (disabled by default).

Test version: download_panel_tweaker-0.2.1pre-fx.xpi (source).

from download_panel_tweaker.

AlexVallat avatar AlexVallat commented on July 19, 2024

Thanks, I've given the test version a try. It's already a great improvement, but from my point of view there are a couple of minor issues with it:

The function I was looking for was to remove the download from the popup panel list, not from the download history completely.

If you have two downloads of the same file, and middle click on one of them, it currently removes both.

If it's possible to have middle clicking the toolbar button remove all the entries from the panel (but not the download history), that would be awesome. I see the green arrow, I know I'm not interested in any of the stuff just downloaded, so I middle click the button and they are all cleared and the arrow turns black. I can always get at them by clicking Show All Downloads to see the main download history, so it's not a dangerous operation.

from download_panel_tweaker.

Infocatcher avatar Infocatcher commented on July 19, 2024

The function I was looking for was to remove the download from the popup panel list, not from the download history completely.

Make sense. I renamed extensions.downloadPanelTweaker.middleClickToRemoveFromHistory preference to ...middleClickToRemoveFromPanel and added extensions.downloadPanelTweaker.middleClickToRemoveFromPanel.clearHistory preference (disabled and without UI, at least for now).

But there is logical issue with Library: "temporary" downloads (from download panel) are shown before "history" downloads. Also looks like "history" downloads may have only one item for one download link.

Test version: download_panel_tweaker-0.2.1pre2-fx.xpi (source).

If it's possible to have middle clicking the toolbar button remove all the entries from the panel (but not the download history), that would be awesome.

Yes, this should be possible, if built-in "Clear List" from panel context menu clears only that list.

from download_panel_tweaker.

AlexVallat avatar AlexVallat commented on July 19, 2024

OK, I've done a spot of investigating Firefox's natural behaviour; as you say, the history downloads have only one item per download link. I don't see that as being a problem, to be honest. The test I did (with Download Panel Tweaker disabled) was:

Download multiple copies of the same file. Note that there are multiple entries both in the panel, and the history window. Restart firefox, which clears the panel. There is now only one entry in the history window, and the "Go to download page" command for it is no longer available.

I have also checked that if I used the Clear List command on the panel, it would remove the temporary downloads and not convert them into history downloads. However, it won't remove any history entries that have already been created, even if they have the same url. To me, that just seems wrong, Clear List ought to just clear the list the same as restarting Firefox would, and the downloads should still be recorded as history entries (with one entry per url). I can understand if you wouldn't want to change the Firefox behaviour, though.

Testing your 0.2.1-pre2-fx, it works properly to remove the temporary download from the panel, but, like the Clear List command, they are not converted to history downloads. This does match the Firefox Clear List command behaviour, but I would argue that it would be more useful to match the behaviour when items naturally come off the temporary list and become history downloads, if possible.

from download_panel_tweaker.

Infocatcher avatar Infocatcher commented on July 19, 2024

Some knowledge.
There is "temporary" downloads in %profile%/downloads.json (displayed in panel) and "history" downloads in %profile%/places.sqlite (displayed in library, but after all temporary downloads.
But "history" downloads are created not for all downloads (for example, for downloaded files, but not for saved pages). Without Download Panel Tweaker only these downloads (except in progress and paused) will be stored (in library).
And with Download Panel Tweaker it's possible to preserve last "temporary" downloads.
And finally we can middle-click to download in panel to remove it from list (from downloads.json). If there is corresponding "history" entry, it will be shown in library after all "temporary" downloads.

Anyway, it's (theoretically) possible to somehow tweak built-in things around history, but this is very difficult (even simple preserving of few last items in downloads.json was too hard).

from download_panel_tweaker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.