Re: [PATCH spice-gtk 08/15] gtk: do not require glib session private fields

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi

On Wed, Nov 26, 2014 at 12:05 AM, Jonathon Jongsma <jjongsma@xxxxxxxxxx> wrote:
> So, you just added internal accessor functions for a bunch of other
> session member variables (_get_webdav_magic(), etc.). But for these, you
> used the GObject data functions. Why are these variables treated
> differently? By using g_object_get|set_data(), you lose some type
> safety, and make things harder to debug since you can't look directly at
> struct members, etc. I'd really rather just add setters/getters for
> these variables.

Right, I should have explained the reason. The problem is gtk-session
and desktop-integration are in the gtk library SpiceSession is in
glib. So far we had the SessionPriv structure shared between the two
libraries, so they could fit their pointers there. But this is no
longer possible when moving the private structure in .c. We could had
more accessors, but they would need to be in public API, and this
isn't supposed to be accessed by API users. Thus, I think GObject data
usage is justified here.


-- 
Marc-André Lureau
_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/spice-devel





[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]