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 582018 - [3.0] Fix GtkWindow-related deprecations
[3.0] Fix GtkWindow-related deprecations
Status: RESOLVED OBSOLETE
Product: gtk+
Classification: Platform
Component: Widget: Other
2.19.x
Other All
: Normal normal
: 3.0
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2009-05-09 22:00 UTC by Cody Russell
Modified: 2010-09-11 19:26 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Proposed patch (103.34 KB, patch)
2009-05-09 22:03 UTC, Cody Russell
none Details | Review

Description Cody Russell 2009-05-09 22:00:41 UTC
gtk+ currently does not build with GSEAL enabled, so in an effort to remedy this I will be posting a series of patches to resolve it.  In order to keep it somewhat manageable I'll do this roughly per-widget.  This is the first, GtkWindow.

Anything that is GSEAL'd is moved into GtkWindowPrivate.  Anything that gets moved here that is depended upon elsewhere in gtk+ gets new API added.  This means that things that were in GtkWindow public struct which are not needed to build gtk+ did not receive new API in this patch, and I'm aware of that and would rather address that later and make this current effort about getting gtk+ building.

New API added:

G_CONST_RETURN gchar *gtk_window_get_wmclass_name  (GtkWindow *window);
G_CONST_RETURN gchar *gtk_window_get_wmclass_class (GtkWindow *window);
void       gtk_window_set_window_type              (GtkWindow *window,
                                                    GtkWindowType window_type);
GtkWindowType gtk_window_get_window_type           (GtkWindow *window);
GdkWindow *gtk_window_get_frame                    (GtkWindow *window);
Comment 1 Cody Russell 2009-05-09 22:03:25 UTC
Created attachment 134327 [details] [review]
Proposed patch
Comment 2 Cody Russell 2009-05-09 22:22:05 UTC
Also, I need to add API documentation for the new functions.  One question about that is what I should list for the "since" version.. not sure if this would go into git HEAD or if it should go into another branch.
Comment 3 Matthias Clasen 2009-05-10 04:43:54 UTC
> Anything that is GSEAL'd is moved into GtkWindowPrivate.

Wait - whats the purpose of the whole GSEAL macro dance then ? My understanding was that stuff is left in place, so that defining away GSEAL would keep old code building ? How is that going to work if you move stuff to private structs ?
Comment 4 Cody Russell 2009-05-10 13:13:38 UTC
But when you enable GSEAL those fields get renamed, so nothing will build and the real data must exist somewhere internally I think.

Maybe I'm getting ahead of myself though.  Maybe the next step is simply to introduce the new APIs and have them work from window->foo instead of private->foo.  I'll talk to mitch or timj and find out if I'm going about this right or not.
Comment 5 Javier Jardón (IRC: jjardon) 2010-01-21 05:16:53 UTC
Hello Cody,

Is there any consensus about this?
Comment 6 Javier Jardón (IRC: jjardon) 2010-09-11 19:26:38 UTC
This is fixed in current master now.