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 701048 - GcrCertificateWidget: inherit from GtkBin, not GtkWidget
GcrCertificateWidget: inherit from GtkBin, not GtkWidget
Status: RESOLVED FIXED
Product: gcr
Classification: Core
Component: General
unspecified
Other All
: Normal normal
: ---
Assigned To: GNOME keyring maintainer(s)
GNOME keyring maintainer(s)
: 702740 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2013-05-26 13:58 UTC by Giovanni Campagna
Modified: 2019-02-22 11:59 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
GcrCertificateWidget: inherit from GtkBin, not GtkWidget (1.78 KB, patch)
2013-05-26 13:58 UTC, Giovanni Campagna
committed Details | Review

Description Giovanni Campagna 2013-05-26 13:58:33 UTC
We use GtkContainer methods, and we have one child.

This is a ABI break, but avoiding it would mean duplicating
all GtkBin code and some of GtkContainer in GcrCertificateWidget,
and probably it would break anyway, because modern Gtk assumes
that all widgets with children are containers.
Comment 1 Giovanni Campagna 2013-05-26 13:58:35 UTC
Created attachment 245332 [details] [review]
GcrCertificateWidget: inherit from GtkBin, not GtkWidget
Comment 2 Stef Walter 2013-05-27 08:27:48 UTC
Interesting. What is the use case that caused this to be a problem for you?

FWIW, I didn't want people to get too intimate with the implementation of a GcrCertificateWidget (its currently uses a GtkTextView) because it may need to change in the future.
Comment 3 Giovanni Campagna 2013-05-27 13:31:05 UTC
I got a crash in empathy-auth-client, when it called gtk_widget_realize on the certificate widget, because the has_window flag is not unset. After fixing that, I got an empty widget, and I saw that the child is not really added to the widget.
I don't know if there were criticals, it's a dbus activated service on which I attached gdb.
Comment 4 Stef Walter 2013-06-18 14:34:08 UTC
I agree. Thanks for the fix. The Gcr ABI is not yet stable, and I don't think anyone has derived from this widget, so lets push this into git master.

Attachment 245332 [details] pushed as cb3320b - GcrCertificateWidget: inherit from GtkBin, not GtkWidget
Comment 5 Stef Walter 2013-09-03 06:42:55 UTC
*** Bug 702740 has been marked as a duplicate of this bug. ***