diff options
author | jstebbins <[email protected]> | 2013-03-01 10:14:00 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2013-03-01 10:14:00 +0000 |
commit | 6039fc23819d1e9e8b5b7440ce6a156a6c46094d (patch) | |
tree | 1d6e2d36af8b8229f98bef66006186ecf58ce100 /gtk/src/callbacks.c | |
parent | a1a0e0e715d31badf58e3a43c02906b994587c90 (diff) |
Improve scan progress granularity
We were only updating progress after completely processing each title.
Now progress is updated as we generate previews as well.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5276 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk/src/callbacks.c')
-rw-r--r-- | gtk/src/callbacks.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/gtk/src/callbacks.c b/gtk/src/callbacks.c index eb98553e3..6e494f26e 100644 --- a/gtk/src/callbacks.c +++ b/gtk/src/callbacks.c @@ -2826,15 +2826,21 @@ ghb_backend_events(signal_user_data_t *ud) } else { - status_str = g_strdup_printf ("Scanning title %d of %d...", + if (status.scan.preview_cur == 0) + status_str = g_strdup_printf("Scanning title %d of %d...", status.scan.title_cur, status.scan.title_count ); + else + status_str = g_strdup_printf( + "Scanning title %d of %d preview %d...", + status.scan.title_cur, status.scan.title_count, + status.scan.preview_cur); + } gtk_label_set_text (label, status_str); g_free(status_str); if (status.scan.title_count > 0) { - gtk_progress_bar_set_fraction (scan_prog, - (gdouble)status.scan.title_cur / status.scan.title_count); + gtk_progress_bar_set_fraction (scan_prog, status.scan.progress); } } else if (status.scan.state & GHB_STATE_SCANDONE) |