[Geany-devel] Opening unmounted GIO URIs

Enrico Tröger enrico.troeger at xxxxx
Sat Feb 4 12:34:05 UTC 2012


On Thu, 02 Feb 2012 14:46:03 +0100, Colomban wrote:


>> if the mount won't finish in a short time, the user doesn't know
>> what's happening and probably only notices that Geany doesn't start
>> because no GUI is shown.
>> So, I think at the very least we would need some sort of timeout, a
>> short timeout, to cancel the mount operation if it takes too long.
>> Not sure what exactly is 'too long', maybe a few seconds.
>> Or even better (and more complex) we would show the user a dialog
>> with a pulsing progressbar or so stating that a mount operation is in
>> progress. A cancel button would be a big bonus but probabaly not
>> necessarily needed.
>
>Good point, here you go with a dialog, pulse & cancel:
>https://github.com/b4n/geany/commit/540e6b28d8ce461b44f6fd4dce32c38167bca99b

Cool!


>Having a modal dialog also has the advantage of blocking user
>interaction on the main window, addressing a part of Lex's worries.
>
>Just as a funny note, implementing all this required some more hackery
>because GVfsDaemon (bridge of all remote FS) doesn't actually honor
>cancellation even though the API is supposed to provide it.

Not so cool.


>So, here it is with a progress dialog & cancellation support.  I tested
>it a bit, particularly the opening a second URI from the CLI while
>waiting to mount a first one, and it looked like it worked fine:
>mounted the stuff and/or asked for details, each after the other, no
>weird concurrency.
>Though, if anyone wants to test it a bit more, it can't be wrong.

Nice.
I'll test it tomorrow maybe if I find time.

One more thought, though this is less important and can be done later
as well: we could move the GIO code into a separate file to have it
separated from the rest. But as said, this is not that important and
can be done later. Just an idea.


Regards,
Enrico

-- 
Get my GPG key from http://www.uvena.de/pub.asc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.geany.org/pipermail/devel/attachments/20120204/c83cf5f3/attachment.pgp>


More information about the Devel mailing list