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 700896 - Rename gtk_widget_class_declare_callback()
Rename gtk_widget_class_declare_callback()
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Class: GtkBuilder
3.9.x
Other Linux
: Normal normal
: ---
Assigned To: GtkBuilder maintainers
GtkBuilder maintainers
Depends on:
Blocks:
 
 
Reported: 2013-05-23 14:31 UTC by Emmanuele Bassi (:ebassi)
Modified: 2013-07-30 04:13 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Emmanuele Bassi (:ebassi) 2013-05-23 14:31:40 UTC
the naming of the macro and the function it's hiding should at least be related.

I do have my doubts as to why the macro exists in the first place — it's not like a function that takes a string and a function pointer requires much more syntactic sugar — but the two should at least hint at each other. there's is a certain distance between "binding" a callback and "declaring" a callback.

the function should be called gtk_widget_class_bind_callback_full(), and the macro can continue being gtk_widget_class_bind_callback().
Comment 1 Tristan Van Berkom 2013-05-30 14:40:51 UTC
(In reply to comment #0)
> the naming of the macro and the function it's hiding should at least be
> related.
> 
> I do have my doubts as to why the macro exists in the first place — it's not
> like a function that takes a string and a function pointer requires much more
> syntactic sugar — but the two should at least hint at each other. there's is a
> certain distance between "binding" a callback and "declaring" a callback.

As I mentioned in bug 700898, originally I had no convenience macro
the C code looked very redundant, I ended up appreciating the macro in
the end.

Actually in this case I had a vararg function originally which took
string / function pointer pairs... but it still looked quite redundant :-/

> the function should be called gtk_widget_class_bind_callback_full(), and the
> macro can continue being gtk_widget_class_bind_callback().

Definitely agree, I'll leave some time and space for others to comment,
and I'll make the change, say this weekend... if nobody comments.

C code will only need to recompile, and I suspect the Vala compiler will
need to change a couple lines of code, shouldn't cause too much churn.
Comment 2 Emmanuele Bassi (:ebassi) 2013-07-05 00:56:01 UTC
patch attached to bug 700898
Comment 3 Matthias Clasen 2013-07-30 04:13:39 UTC
This was fixed