Thu, 07 Feb 2019 04:54:05 -0500
Use G_DEFINE_TYPE_WITH_PRIVATE for Purple*Presence.
/* purple * * Purple is the legal property of its developers, whose names are too numerous * to list here. Please refer to the COPYRIGHT file distributed with this * source distribution. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA * */ #ifndef _ICQ_H_ #define _ICQ_H_ #include "oscar.h" #define ICQ_TYPE_PROTOCOL (icq_protocol_get_type()) #define ICQ_PROTOCOL(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), ICQ_TYPE_PROTOCOL, ICQProtocol)) #define ICQ_PROTOCOL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), ICQ_TYPE_PROTOCOL, ICQProtocolClass)) #define ICQ_IS_PROTOCOL(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), ICQ_TYPE_PROTOCOL)) #define ICQ_IS_PROTOCOL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), ICQ_TYPE_PROTOCOL)) #define ICQ_PROTOCOL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), ICQ_TYPE_PROTOCOL, ICQProtocolClass)) typedef struct _ICQProtocol { OscarProtocol parent; } ICQProtocol; typedef struct _ICQProtocolClass { OscarProtocolClass parent_class; } ICQProtocolClass; /** * Registers the ICQProtocol type in the type system. */ void icq_protocol_register_type(PurplePlugin *plugin); /** * Returns the GType for the ICQProtocol object. */ G_MODULE_EXPORT GType icq_protocol_get_type(void); #endif /* _ICQ_H_ */