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 531002 - behavior of setting filename for gtk_file_chooser_button depends on dialog open/closed
behavior of setting filename for gtk_file_chooser_button depends on dialog op...
Status: RESOLVED DUPLICATE of bug 691040
Product: gtk+
Classification: Platform
Component: Widget: GtkFileChooser
2.12.x
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
Federico Mena Quintero
Depends on:
Blocks:
 
 
Reported: 2008-05-02 04:40 UTC by Steffen Gutmann
Modified: 2013-09-23 20:48 UTC
See Also:
GNOME target: ---
GNOME version: 2.19/2.20


Attachments
Test case for the bug described (1014 bytes, text/x-csrc)
2008-05-02 04:41 UTC, Steffen Gutmann
Details

Description Steffen Gutmann 2008-05-02 04:40:21 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.
Comment 1 Steffen Gutmann 2008-05-02 04:41:26 UTC
Created attachment 110260 [details]
Test case for the bug described
Comment 2 Federico Mena Quintero 2013-09-23 20:48:04 UTC

*** This bug has been marked as a duplicate of bug 691040 ***