[Conkeror] [PATCH] save_uri: optionally use a temporary download file

David Kettler kettler at internode.on.net
Thu Feb 12 02:36:12 PST 2009


>> I added another property, finished_function, to download_info.  It
>> would be possible to use download_finished_hook, but that's probably
>> inappropriate for internal functionality like this.  It would be
>> possible to subsume the shell_command stuff into finished_function.
> 
> I think it makes sense to use download_finished_hook, even though this
> is functionality of the download manager itself, since it adds less
> overhead and I don't see any reason not to.

I've done so in the follow up patch, but I'm not pleased with it.

> The shell command handling
> is done specially because the download buffer displays information about
> the shell command.

Yes, I see.  The temporary download also has special info displayed, but 
it uses the existing displayName property for that.

>> The file rename will foil download-delete-target.  I was undecided as
>> to whether that should be fixed or if it's better as is.  The deletion uses
>>   download_manager_service.removeDownload(this.id);
>> so it will either need to be handled separately, or the state of the
>> nsIDownloadManager will need fiddling.

That's fixed in the followup, but required changes to the way 
target_file is managed.

> The built-in file saving uses a temporary file as well; perhaps this can
> somehow make use of some of the same facilities for handling that?

I'm making use of displayName; I don't think there's much more we can 
use.  I'm only going by the doco though; I haven't examined the firefox 
code.

regards, David.




More information about the Conkeror mailing list