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 152061 - add an option to show recorders only to bacon-cd-selection
add an option to show recorders only to bacon-cd-selection
Status: RESOLVED FIXED
Product: nautilus-cd-burner
Classification: Deprecated
Component: cd-burner
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Nautilus CD Burner Maintainers
Nautilus CD Burner Maintainers
Depends on:
Blocks: 152387
 
 
Reported: 2004-09-07 13:49 UTC by William Jon McCann
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch for HEAD (4.97 KB, patch)
2004-09-07 13:59 UTC, William Jon McCann
none Details | Review
tarball of test program (5.61 KB, application/x-tar)
2004-09-07 17:05 UTC, William Jon McCann
  Details
updated patch (5.44 KB, patch)
2004-09-07 17:21 UTC, William Jon McCann
none Details | Review
updated patch (5.58 KB, patch)
2004-09-07 19:02 UTC, William Jon McCann
accepted-commit_after_freeze Details | Review
updated patch (5.29 KB, patch)
2004-09-10 17:16 UTC, William Jon McCann
none Details | Review

Description William Jon McCann 2004-09-07 13:49:58 UTC
It would be useful to have an option to show only recorder devices in
bacon-cd-selection.
Comment 1 William Jon McCann 2004-09-07 13:59:22 UTC
Created attachment 31372 [details] [review]
patch for HEAD
Comment 2 Bastien Nocera 2004-09-07 14:11:47 UTC
William, could you write a simple test program that shows the cd selection
widget, with checkboxes to switch the "show-recorders-only", and "file-image"
properties on or off on the fly?
That would allow for people to test those changes, and make sure they're robust.
Comment 3 William Jon McCann 2004-09-07 17:05:08 UTC
Created attachment 31382 [details]
tarball of test program
Comment 4 William Jon McCann 2004-09-07 17:21:16 UTC
Created attachment 31383 [details] [review]
updated patch

Well, the test program was useful.  It found an existing off by one bug in the
file-image property set callback!

Also showed that the new function compare_drives needed to be more robust.

Unfortunately, I only have a recorder on my test machine.  So, I'm not really
able to test the show-recorders-only logic.  Can someone with a CDROM device
please give this a try?
Comment 5 Bastien Nocera 2004-09-07 17:33:28 UTC
You can fake it by modifying cd-drive.c directly.
Comment 6 William Jon McCann 2004-09-07 19:02:04 UTC
Created attachment 31392 [details] [review]
updated patch

Ok, I faked it.  This version fixes:

 - insert into list instead of append since file-image is assumed to be last
 - don't remove item from list before storing link to previous item
Comment 7 Bastien Nocera 2004-09-10 16:12:28 UTC
I've committed the off-by-one fix, and a test program (this one doesn't rely on
glade). Could you update your patch?
Comment 8 William Jon McCann 2004-09-10 17:16:19 UTC
Created attachment 31475 [details] [review]
updated patch
Comment 9 Bastien Nocera 2004-09-12 15:45:24 UTC
I don't like that:
+	bcs->priv->cdroms = scan_for_cdroms (show_recorders_only, show_file_image);
because if you create the recorder without recorders shown, showing them
wouldn't add any drives to the list.

The rest looks OK.
Comment 10 Bastien Nocera 2004-09-12 15:54:24 UTC
My mistake, it will work because we scan again.
That will need to be cleaned up in 2.10, so that we only scan when creating the
widget.
Comment 11 Bastien Nocera 2004-09-14 10:19:28 UTC
2004-09-10  William Jon McCann  <mccann@jhu.edu>

        * bacon-cd-selection.c (bacon_cd_selection_class_init)
        (cdrom_combo_box, bacon_cd_selection_new, compare_drives)
        (bacon_cd_selection_set_recorders_only)
        (bacon_cd_selection_set_property)
        (bacon_cd_selection_get_property):
        Add show-recorders-only property.  Fixes #152061.