After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 78789 - No progress information when computing size of dirs
No progress information when computing size of dirs
Status: RESOLVED FIXED
Product: nautilus
Classification: Core
Component: File and Folder Operations
2.11.x
Other All
: Normal minor
: ---
Assigned To: Nautilus Maintainers
Nautilus Maintainers
: 711256 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2002-04-15 17:48 UTC by Ettore Perazzoli
Modified: 2013-11-01 13:01 UTC
See Also:
GNOME target: ---
GNOME version: 2.11/2.12


Attachments
Add a spinner when computing the contents of folders (9.00 KB, patch)
2012-09-08 01:08 UTC, William Jon McCann
reviewed Details | Review
Add a spinner when computing the contents of folders (9.15 KB, patch)
2012-09-09 22:29 UTC, William Jon McCann
committed Details | Review
Only show the spinner if the deep count take longer than a second. (2.86 KB, patch)
2012-09-09 22:29 UTC, William Jon McCann
needs-work Details | Review
Only show the spinner if the deep count take longer than a second. (2.92 KB, patch)
2012-09-10 12:54 UTC, William Jon McCann
committed Details | Review

Description Ettore Perazzoli 2002-04-15 17:48:52 UTC
If I go File -> Show Properties for a directory, it starts computing the
number of files and the space occupied by the directory on the disk.  Which
is good.

On the other hand, it doesn't give me a hint as to whether the computation
is still in progress.  So if you look at the number, you are not sure if
it's going to change in another few seconds, or if it's the final one.

It should probably only display the size after it's been computed instead.
Comment 1 Christian Neumair 2005-07-23 12:23:29 UTC
I'd rather suggest having a " (still counting)", or " or more" appended to the
item count, or "at least " in prepended. Usability crew, what do you think?
Comment 2 Calum Benson 2005-07-26 11:01:54 UTC
I quite like the "At least" suggestion, although I don't know how l10n friendly
it is.

Another option might be to use the > or + symbols:

>115907 items, totalling >1.9 GB
115907+ items, totalling 1.9+ GB

The ">" option is universal but a bit geeky; putting "+" after a number to mean
"at least" is a little friendlier, but I don't know if it's in such common
usage.  If you went with either of those ideas, you'd probably also want to
round off the file and disk space count to a few significant figures:

>115000 items, totalling >1.9GB
200+ items, totalling 100+ KB

otherwise it looks (slightly) silly, IMHO... a bit like a newspaper headline
that reads "New Stadium to Cost Nearly $1,456,43.67" or something :)
Comment 3 Christian Neumair 2005-07-26 11:56:50 UTC
While we're at it, we could also show orders of magnitude while counting, i.e.

 n >= 10^2 items, totalling >= 1*10^9 B

just kidding...seriously, I think *prepending* the word "at least" shows
instantly that we're not yet finished and incomplete counts IMHO don't really
help if you're not interested in lower bounds, which is very uncommon for file
sizes.
Comment 4 Sense Hofstede 2009-11-12 16:44:58 UTC
The same request has been made in the Ubuntu bug tracker at Launchpad. PGScooter suggested in the bug report at https://launchpad.net/bugs/386233 to indicate whether Nautilus is still updating the directory size.

Instead of using words he suggested to use the animated gif throbber you'll usually find next to your mouse.
Comment 5 William Jon McCann 2012-09-08 01:08:47 UTC
Created attachment 223797 [details] [review]
Add a spinner when computing the contents of folders

In the process fix a problem where we were cycling in the
callbacks from file "changed" and "updated_deep_count_in_progress".
Comment 6 Cosimo Cecchi 2012-09-09 20:25:37 UTC
Review of attachment 223797 [details] [review]:

Thanks, looks generally good to me; a couple of comments below.

::: src/nautilus-properties-window.c
@@ +2121,3 @@
 	 */
 	if (window->details->deep_count_finished &&
+	    g_list_length (window->details->deep_count_files) > 0) {

Since g_list_length() traverses the list every time, I think it could be worth to save the length in a separate variable here.

@@ +5105,3 @@
+	for (l = window->details->deep_count_files; l != NULL; l = l->next) {
+		stop_deep_count_for_file (window, l->data);
+	}

Should also g_list_free(window->details->deep_count_files) here I think.
Comment 7 William Jon McCann 2012-09-09 22:29:04 UTC
Created attachment 223868 [details] [review]
Add a spinner when computing the contents of folders

In the process fix a problem where we were cycling in the
callbacks from file "changed" and "updated_deep_count_in_progress".
Comment 8 William Jon McCann 2012-09-09 22:29:06 UTC
Created attachment 223869 [details] [review]
Only show the spinner if the deep count take longer than a second.

This avoids flashing it on and off when it isn't needed.
Comment 9 Cosimo Cecchi 2012-09-10 04:07:47 UTC
Review of attachment 223868 [details] [review]:

Looks good.
Comment 10 Cosimo Cecchi 2012-09-10 04:11:18 UTC
Review of attachment 223869 [details] [review]:

::: src/nautilus-properties-window.c
@@ +965,3 @@
 	gtk_widget_hide (window->details->directory_contents_spinner);
+	if (window->details->deep_count_spinner_timeout_id > 0) {
+		g_source_remove (window->details->deep_count_spinner_timeout_id);

Need to reset deep_count_spinner_timeout_id here too, or we'll possibly try to remove again the source id in real_destroy()
Comment 11 William Jon McCann 2012-09-10 12:54:58 UTC
Created attachment 223907 [details] [review]
Only show the spinner if the deep count take longer than a second.

This avoids flashing it on and off when it isn't needed.
Comment 12 Cosimo Cecchi 2012-09-10 12:57:42 UTC
Review of attachment 223907 [details] [review]:

++
Comment 13 William Jon McCann 2012-09-10 13:53:14 UTC
Attachment 223868 [details] pushed as 5a00dae - Add a spinner when computing the contents of folders
Attachment 223907 [details] pushed as 0b79e43 - Only show the spinner if the deep count take longer than a second.
Comment 14 António Fernandes 2013-11-01 13:01:03 UTC
*** Bug 711256 has been marked as a duplicate of this bug. ***