[patch] consistent file save UI behaviour for overwriting files
The UI for downloading files is split between Dillo (which prompts for a file to save to) and the downloads DPI (which prompts for another file if the first file already exists). This leads to inconsistent behaviour for "Save link as file" depending on whether the URL is cached or not - if it is cached then any existing file is silently overwritten but if it is not cached we go to the downloads DPI which prompts before overwriting anything. These two patches move the UI logic from the downloads DPI into Dillo. This puts all the UI logic in the same place and ensures consistent behaviour for "Save link as file" whether or not the URL is cached. http://starurchin.org/dillo/patch/downloads-dpi_file_test_remove.html http://starurchin.org/dillo/patch/uicmd-cc_file_test_add.html Comments? Shall I push this? Regards, Jeremy Henty
Jeremy wrote:
These two patches move the UI logic from the downloads DPI into Dillo. This puts all the UI logic in the same place and ensures consistent behaviour for "Save link as file" whether or not the URL is cached.
Seems good to have the logic in dillo. I imagine a later step would be to teach UIcmd_save_file_check() about file permissions, errno possibilities, etc.
corvid wrote:
Jeremy wrote:
These two patches move the UI logic from the downloads DPI into Dillo. This puts all the UI logic in the same place and ensures consistent behaviour for "Save link as file" whether or not the URL is cached.
Seems good to have the logic in dillo.
OK, it's in.
I imagine a later step would be to teach UIcmd_save_file_check() about file permissions, errno possibilities, etc.
I guess so, although in the case of the file not existing you would want to check whether the missing component was the last one in the path or not. Regards, Jeremy Henty
participants (2)
-
corvid@lavabit.com
-
onepoint@starurchin.org