| 27 */ |
27 */ |
| 28 |
28 |
| 29 #include <glib.h> |
29 #include <glib.h> |
| 30 #include <glib-object.h> |
30 #include <glib-object.h> |
| 31 |
31 |
| 32 #define PURPLE_TYPE_CIRCULAR_BUFFER (purple_circular_buffer_get_type()) |
32 G_BEGIN_DECLS |
| 33 #define PURPLE_CIRCULAR_BUFFER(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), PURPLE_TYPE_CIRCULAR_BUFFER, PurpleCircularBuffer)) |
|
| 34 #define PURPLE_CIRCULAR_BUFFER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), PURPLE_TYPE_CIRCULAR_BUFFER, PurpleCircularBufferClass)) |
|
| 35 #define PURPLE_IS_CIRCULAR_BUFFER(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), PURPLE_TYPE_CIRCULAR_BUFFER)) |
|
| 36 #define PURPLE_IS_CIRCULAR_BUFFER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), PURPLE_TYPE_CIRCULAR_BUFFER)) |
|
| 37 #define PURPLE_CIRCULAR_BUFFER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), PURPLE_TYPE_CIRCULAR_BUFFER, PurpleCircularBufferClass)) |
|
| 38 |
33 |
| 39 typedef struct _PurpleCircularBuffer PurpleCircularBuffer; |
34 #define PURPLE_TYPE_CIRCULAR_BUFFER (purple_circular_buffer_get_type()) |
| 40 typedef struct _PurpleCircularBufferClass PurpleCircularBufferClass; |
|
| 41 |
35 |
| 42 struct _PurpleCircularBuffer { |
36 G_DECLARE_DERIVABLE_TYPE(PurpleCircularBuffer, purple_circular_buffer, PURPLE, |
| 43 /*< private >*/ |
37 CIRCULAR_BUFFER, GObject) |
| 44 GObject parent; |
|
| 45 }; |
|
| 46 |
38 |
| 47 struct _PurpleCircularBufferClass { |
39 struct _PurpleCircularBufferClass { |
| 48 /*< private >*/ |
40 /*< private >*/ |
| 49 GObjectClass parent; |
41 GObjectClass parent; |
| 50 |
42 |
| 56 void (*purple_reserved1)(void); |
48 void (*purple_reserved1)(void); |
| 57 void (*purple_reserved2)(void); |
49 void (*purple_reserved2)(void); |
| 58 void (*purple_reserved3)(void); |
50 void (*purple_reserved3)(void); |
| 59 void (*purple_reserved4)(void); |
51 void (*purple_reserved4)(void); |
| 60 }; |
52 }; |
| 61 |
|
| 62 G_BEGIN_DECLS |
|
| 63 |
|
| 64 GType purple_circular_buffer_get_type(void); |
|
| 65 |
53 |
| 66 /** |
54 /** |
| 67 * purple_circular_buffer_new: |
55 * purple_circular_buffer_new: |
| 68 * @growsize: The amount that the buffer should grow the first time data |
56 * @growsize: The amount that the buffer should grow the first time data |
| 69 * is appended and every time more space is needed. Pass in |
57 * is appended and every time more space is needed. Pass in |