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 311842 - gtk_entry_set_text produces double callback, the first with empty string
gtk_entry_set_text produces double callback, the first with empty string
Status: RESOLVED DUPLICATE of bug 64998
Product: gtk+
Classification: Platform
Component: Widget: Other
2.6.x
Other All
: Normal major
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2005-07-28 10:08 UTC by Yury Aliaev
Modified: 2005-07-28 14:44 UTC
See Also:
GNOME target: ---
GNOME version: 2.9/2.10


Attachments
Program that demonstrates the bug (2.43 KB, text/x-csrc)
2005-07-28 10:09 UTC, Yury Aliaev
Details

Description Yury Aliaev 2005-07-28 10:08:41 UTC
Please describe the problem:
When changing the GtkEntry content with gtk_entry_set_text function the callback
with "changed" signal occures twice, first time gtk_entry_get_text returns empty
string, second time it returns the normal content. Besides it is an overhead
(callback function calls twice) in my case it brakes the program logic. The
simple attached program illustrates this bug.

Steps to reproduce:
1. Complile the test program with standard Gtk+ compiler and linker options
2. Press "Set text..." buttons
3. See output in the console


Actual results:
At each button press the output will be twice: first time with empty string<
second time with normal string

Expected results:
Only single output per button press with the appropriate string

Does this happen every time?
Yes

Other information:
See attached program
Comment 1 Yury Aliaev 2005-07-28 10:09:47 UTC
Created attachment 49870 [details]
Program that demonstrates the bug
Comment 2 Owen Taylor 2005-07-28 14:44:50 UTC

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