Re: Multi-thread for opening new folders



On Mon, 2004-10-11 at 11:33 -0400, Dave Ahlswede wrote:
> At the moment in Nautilus, when you open a new folder, the rest of the
> app is put on hold until it's finished displaying. With small folders,
> this isn't a problem, but if you happen to open one with several hundred
> files, there's a significant delay, where you can't do anything
> file-manager related, you have non-repainting windows, etc.
> 
> I suspect this wasn't nearly as much of a problem before spatial mode
> was introduced, but it's very inconvenient. Would it be feasible for
> Nautilus to start a separate thread for the opening of a new folder, so
> that the application doesn't seem to grind to a halt? 

Generally nautilus doesn't do any synchronous i/o in the main thread, so
it shouldn't block like this. At times we do non-i/o things that take a
lot of time, like sorting or laying out the icons in the window when
we've read all the data, but that shouldn't take much time.

In fact, while reading /usr/lib with 2108 items I can use nautilus to
browse other windows fine. When the directory is finally loaded there is
a delay of slighly less than a second. Its not perfect, but imho
acceptable compared to the problems threading the UI would cause.

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Alexander Larsson                                            Red Hat, Inc 
                   alexl redhat com    alla lysator liu se 
He's an obese ninja gangster possessed of the uncanny powers of an insect. 
She's a chain-smoking belly-dancing doctor descended from a line of powerful 
witches. They fight crime! 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]