On Mon, 27 Jul 2009 11:21:41 +0200, Jonas wrote:
Hi there,
I'd like to see threaded file handling (read, write, ...) in Geany because I'm mostly working directly on servers and waiting for one of that dozens of files to save (or open) becomes a torture quite fast.
Instead of waiting for one file to get saved I could work on another file which logically speaking saves time.
Some time ago, I worked on this and if I didn't post the patch somewhere on the net (mailing list, bug tracker, I don't remember) I probably have it laying around on my hard disk somewhere.
The main problem with threaded or asynchronous file operations is that you don't have any feedback of the result of the requested operation. That is, for file opening is almost completely useless because at the very first we need the contents of the file to continue opening it, obviously. So, when the user chooses to open a file from a remote server which may take a few seconds, with asynchronous read nothing would happen in Geany. The file open dialog would be closed and Geany would wait for the server to respond while the user just don't see anything and thinks something went wrong. Then, a few seconds later the server finally responds and Geany starts opening the document while the user is doing something else and is even more confused what's happening. Sorry, I don't see how this could be an improvement.
Regarding file saving: this is more or less easier to realise and also more useful but also for plain file saving, i.e. when the user clicks the Save button or hit Ctrl-S. But we do most save operations implicitly in Geany e.g. when compiling/building/running the current file. At this point we need synchronous saving otherwise the whole point in saving a file prior to an operation which relies on it becomes useless.
Regards, Enrico