GNOME Bugzilla – Bug 531002
behavior of setting filename for gtk_file_chooser_button depends on dialog open/closed
Last modified: 2013-09-23 20:48:04 UTC
Please describe the problem: If the dialog attached to a GtkFileChooserButton is open, calling gtk_file_chooser_set_filename on the GtkFileChooserButton only sets the selection in the dialog but does not update the label in the GtkFileChooserButton. Steps to reproduce: 1. Compile and run the attached test case 2. Click the push button. This sets the file button to "/etc/passwd". 3. Click the file button, choose "/etc/group" and leave the dialog with 'Ok'. 4. Click the file button again and leave the dialog open. 5. Click the push button. This changes the selection in the file dialog but does not update the file button. Actual results: The label in the file button is not updated on action 5. Expected results: Several possibilities (any of them would solve this issue): (a) Action 5. also updates the file button (the "old path") (b) Make the dialog always modal such that the push button cannot be pressed. (c) Provide a different API for setting the filename. Does this happen every time? Yes Other information: Use case: a database application where one record is displayed at a time, the record contains a filename (interfaced using the file button) and the user can change between records while the file button's dialog is open.
Created attachment 110260 [details] Test case for the bug described
*** This bug has been marked as a duplicate of bug 691040 ***