diff options
author | Hans de Goede <hdegoede@redhat.com> | 2011-08-30 16:47:50 +0200 |
---|---|---|
committer | Hans de Goede <hdegoede@redhat.com> | 2011-08-30 16:47:50 +0200 |
commit | 5e56a2a5c6c90959a46682244ff7f50506c2920c (patch) | |
tree | 8d85510c45adcce4f06fe051b1343240b75687d5 | |
parent | 532450c76dfe100690b027b96e02d986895c1e21 (diff) |
Rename my_foo private datatypes to MyFooPrivate
We were using the gobject standard notation of MyFooPrivate everywhere
except for 3 places, this brings these 3 into sync, with what we do elsewhere.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
-rw-r--r-- | gtk/smartcard-manager.c | 10 | ||||
-rw-r--r-- | gtk/smartcard-manager.h | 4 | ||||
-rw-r--r-- | gtk/spice-gstaudio.c | 40 | ||||
-rw-r--r-- | gtk/spice-gstaudio.h | 4 | ||||
-rw-r--r-- | gtk/spice-pulse.c | 56 | ||||
-rw-r--r-- | gtk/spice-pulse.h | 4 |
6 files changed, 59 insertions, 59 deletions
diff --git a/gtk/smartcard-manager.c b/gtk/smartcard-manager.c index 0ff96b1..a192bd6 100644 --- a/gtk/smartcard-manager.c +++ b/gtk/smartcard-manager.c @@ -50,9 +50,9 @@ /* gobject glue */ #define SPICE_SMARTCARD_MANAGER_GET_PRIVATE(obj) \ - (G_TYPE_INSTANCE_GET_PRIVATE ((obj), SPICE_TYPE_SMARTCARD_MANAGER, spice_smartcard_manager)) + (G_TYPE_INSTANCE_GET_PRIVATE ((obj), SPICE_TYPE_SMARTCARD_MANAGER, SpiceSmartcardManagerPrivate)) -struct spice_smartcard_manager { +struct _SpiceSmartcardManagerPrivate { guint monitor_id; /* software smartcard reader, the certificates to use for this reader @@ -100,7 +100,7 @@ static gboolean smartcard_monitor_dispatch(VEvent *event, gpointer user_data); static void spice_smartcard_manager_init(SpiceSmartcardManager *smartcard_manager) { - spice_smartcard_manager *priv; + SpiceSmartcardManagerPrivate *priv; priv = SPICE_SMARTCARD_MANAGER_GET_PRIVATE(smartcard_manager); smartcard_manager->priv = priv; @@ -119,7 +119,7 @@ static void spice_smartcard_manager_dispose(GObject *gobject) static void spice_smartcard_manager_finalize(GObject *gobject) { - spice_smartcard_manager *priv; + SpiceSmartcardManagerPrivate *priv; priv = SPICE_SMARTCARD_MANAGER_GET_PRIVATE(gobject); if (priv->monitor_id != 0) { @@ -223,7 +223,7 @@ static void spice_smartcard_manager_class_init(SpiceSmartcardManagerClass *klass gobject_class->dispose = spice_smartcard_manager_dispose; gobject_class->finalize = spice_smartcard_manager_finalize; - g_type_class_add_private(klass, sizeof(spice_smartcard_manager)); + g_type_class_add_private(klass, sizeof(SpiceSmartcardManagerPrivate)); } /* ------------------------------------------------------------------ */ diff --git a/gtk/smartcard-manager.h b/gtk/smartcard-manager.h index d1f8b88..24d9f92 100644 --- a/gtk/smartcard-manager.h +++ b/gtk/smartcard-manager.h @@ -35,7 +35,7 @@ G_BEGIN_DECLS typedef struct _SpiceSmartcardManager SpiceSmartcardManager; typedef struct _SpiceSmartcardManagerClass SpiceSmartcardManagerClass; -typedef struct spice_smartcard_manager spice_smartcard_manager; +typedef struct _SpiceSmartcardManagerPrivate SpiceSmartcardManagerPrivate; typedef struct _SpiceSmartcardReader SpiceSmartcardReader; struct _SpiceSmartcardManager @@ -43,7 +43,7 @@ struct _SpiceSmartcardManager GObject parent; /*< private >*/ - spice_smartcard_manager *priv; + SpiceSmartcardManagerPrivate *priv; /* Do not add fields to this struct */ }; diff --git a/gtk/spice-gstaudio.c b/gtk/spice-gstaudio.c index c1ff979..d8580e7 100644 --- a/gtk/spice-gstaudio.c +++ b/gtk/spice-gstaudio.c @@ -30,7 +30,7 @@ #include "spice-session.h" #define SPICE_GSTAUDIO_GET_PRIVATE(obj) \ - (G_TYPE_INSTANCE_GET_PRIVATE((obj), SPICE_TYPE_GSTAUDIO, spice_gstaudio)) + (G_TYPE_INSTANCE_GET_PRIVATE((obj), SPICE_TYPE_GSTAUDIO, SpiceGstaudioPrivate)) G_DEFINE_TYPE(SpiceGstAudio, spice_gstaudio, SPICE_TYPE_AUDIO) @@ -42,7 +42,7 @@ struct stream { guint channels; }; -struct spice_gstaudio { +struct _SpiceGstaudioPrivate { SpiceSession *session; SpiceChannel *pchannel; SpiceChannel *rchannel; @@ -80,7 +80,7 @@ void stream_dispose(struct stream *s) static void spice_gstaudio_dispose(GObject *obj) { - spice_gstaudio *p; + SpiceGstaudioPrivate *p; SPICE_DEBUG("%s", __FUNCTION__); p = SPICE_GSTAUDIO_GET_PRIVATE(obj); @@ -104,7 +104,7 @@ static void spice_gstaudio_dispose(GObject *obj) static void spice_gstaudio_init(SpiceGstAudio *pulse) { - spice_gstaudio *p; + SpiceGstaudioPrivate *p; p = pulse->priv = SPICE_GSTAUDIO_GET_PRIVATE(pulse); memset(p, 0, sizeof(*p)); @@ -117,13 +117,13 @@ static void spice_gstaudio_class_init(SpiceGstAudioClass *klass) gobject_class->finalize = spice_gstaudio_finalize; gobject_class->dispose = spice_gstaudio_dispose; - g_type_class_add_private(klass, sizeof(spice_gstaudio)); + g_type_class_add_private(klass, sizeof(SpiceGstaudioPrivate)); } static void record_new_buffer(GstAppSink *appsink, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; GstMessage *msg; g_return_if_fail(p != NULL); @@ -135,7 +135,7 @@ static void record_new_buffer(GstAppSink *appsink, gpointer data) static void record_stop(SpiceRecordChannel *channel, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; SPICE_DEBUG("%s", __FUNCTION__); if (p->record.pipe) @@ -145,7 +145,7 @@ static void record_stop(SpiceRecordChannel *channel, gpointer data) static gboolean record_bus_cb(GstBus *bus, GstMessage *msg, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; g_return_val_if_fail(p != NULL, FALSE); @@ -177,7 +177,7 @@ static void record_start(SpiceRecordChannel *channel, gint format, gint channels gint frequency, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; g_return_if_fail(p != NULL); g_return_if_fail(format == SPICE_AUDIO_FMT_S16); @@ -233,7 +233,7 @@ static void channel_event(SpiceChannel *channel, SpiceChannelEvent event, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; switch (event) { case SPICE_CHANNEL_OPENED: @@ -257,7 +257,7 @@ static void channel_event(SpiceChannel *channel, SpiceChannelEvent event, static void playback_stop(SpicePlaybackChannel *channel, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = SPICE_GSTAUDIO_GET_PRIVATE(gstaudio); + SpiceGstaudioPrivate *p = SPICE_GSTAUDIO_GET_PRIVATE(gstaudio); if (p->playback.pipe) gst_element_set_state(p->playback.pipe, GST_STATE_READY); @@ -270,7 +270,7 @@ static void playback_stop(SpicePlaybackChannel *channel, gpointer data) static gboolean update_mmtime_timeout_cb(gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = SPICE_GSTAUDIO_GET_PRIVATE(gstaudio); + SpiceGstaudioPrivate *p = SPICE_GSTAUDIO_GET_PRIVATE(gstaudio); GstQuery *q; q = gst_query_new_latency(); @@ -289,7 +289,7 @@ static void playback_start(SpicePlaybackChannel *channel, gint format, gint chan gint frequency, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = SPICE_GSTAUDIO_GET_PRIVATE(gstaudio); + SpiceGstaudioPrivate *p = SPICE_GSTAUDIO_GET_PRIVATE(gstaudio); g_return_if_fail(p != NULL); g_return_if_fail(format == SPICE_AUDIO_FMT_S16); @@ -342,7 +342,7 @@ static void playback_data(SpicePlaybackChannel *channel, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = SPICE_GSTAUDIO_GET_PRIVATE(gstaudio); + SpiceGstaudioPrivate *p = SPICE_GSTAUDIO_GET_PRIVATE(gstaudio); GstBuffer *buf; g_return_if_fail(p != NULL); @@ -360,7 +360,7 @@ static void playback_volume_changed(GObject *object, GParamSpec *pspec, gpointer GstElement *e; guint16 *volume; guint nchannels; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; gdouble vol; if (!p->playback.sink) @@ -391,7 +391,7 @@ static void playback_volume_changed(GObject *object, GParamSpec *pspec, gpointer static void playback_mute_changed(GObject *object, GParamSpec *pspec, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; GstElement *e; gboolean mute; @@ -415,7 +415,7 @@ static void playback_mute_changed(GObject *object, GParamSpec *pspec, gpointer d static void record_volume_changed(GObject *object, GParamSpec *pspec, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; GstElement *e; guint16 *volume; guint nchannels; @@ -452,7 +452,7 @@ static void record_volume_changed(GObject *object, GParamSpec *pspec, gpointer d static void record_mute_changed(GObject *object, GParamSpec *pspec, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; GstElement *e; gboolean mute; @@ -477,7 +477,7 @@ static void record_mute_changed(GObject *object, GParamSpec *pspec, gpointer dat static void channel_new(SpiceSession *s, SpiceChannel *channel, gpointer data) { SpiceGstAudio *gstaudio = data; - spice_gstaudio *p = gstaudio->priv; + SpiceGstaudioPrivate *p = gstaudio->priv; if (SPICE_IS_PLAYBACK_CHANNEL(channel)) { g_return_if_fail(p->pchannel == NULL); @@ -518,7 +518,7 @@ SpiceGstAudio *spice_gstaudio_new(SpiceSession *session, GMainContext *context, const char *name) { SpiceGstAudio *gstaudio; - spice_gstaudio *p; + SpiceGstaudioPrivate *p; GList *list; gst_init(NULL, NULL); diff --git a/gtk/spice-gstaudio.h b/gtk/spice-gstaudio.h index ba2b71a..b043f85 100644 --- a/gtk/spice-gstaudio.h +++ b/gtk/spice-gstaudio.h @@ -33,11 +33,11 @@ G_BEGIN_DECLS typedef struct _SpiceGstAudio SpiceGstAudio; typedef struct _SpiceGstAudioClass SpiceGstAudioClass; -typedef struct spice_gstaudio spice_gstaudio; +typedef struct _SpiceGstaudioPrivate SpiceGstaudioPrivate; struct _SpiceGstAudio { SpiceAudio parent; - spice_gstaudio *priv; + SpiceGstaudioPrivate *priv; /* Do not add fields to this struct */ }; diff --git a/gtk/spice-pulse.c b/gtk/spice-pulse.c index 5c9fd4c..dce4e9c 100644 --- a/gtk/spice-pulse.c +++ b/gtk/spice-pulse.c @@ -24,7 +24,7 @@ #include <pulse/pulseaudio.h> #define SPICE_PULSE_GET_PRIVATE(obj) \ - (G_TYPE_INSTANCE_GET_PRIVATE((obj), SPICE_TYPE_PULSE, spice_pulse)) + (G_TYPE_INSTANCE_GET_PRIVATE((obj), SPICE_TYPE_PULSE, SpicePulsePrivate)) struct stream { pa_sample_spec spec; @@ -35,7 +35,7 @@ struct stream { gboolean started; }; -struct spice_pulse { +struct _SpicePulsePrivate { SpiceSession *session; SpiceChannel *pchannel; SpiceChannel *rchannel; @@ -77,7 +77,7 @@ static void channel_new(SpiceSession *s, SpiceChannel *channel, static void spice_pulse_finalize(GObject *obj) { - spice_pulse *p; + SpicePulsePrivate *p; p = SPICE_PULSE_GET_PRIVATE(obj); @@ -92,7 +92,7 @@ static void spice_pulse_finalize(GObject *obj) static void spice_pulse_dispose(GObject *obj) { - spice_pulse *p; + SpicePulsePrivate *p; SPICE_DEBUG("%s", __FUNCTION__); p = SPICE_PULSE_GET_PRIVATE(obj); @@ -139,7 +139,7 @@ static void spice_pulse_dispose(GObject *obj) static void spice_pulse_init(SpicePulse *pulse) { - spice_pulse *p; + SpicePulsePrivate *p; p = pulse->priv = SPICE_PULSE_GET_PRIVATE(pulse); memset(p, 0, sizeof(*p)); @@ -152,7 +152,7 @@ static void spice_pulse_class_init(SpicePulseClass *klass) gobject_class->finalize = spice_pulse_finalize; gobject_class->dispose = spice_pulse_dispose; - g_type_class_add_private(klass, sizeof(spice_pulse)); + g_type_class_add_private(klass, sizeof(SpicePulsePrivate)); } /* ------------------------------------------------------------------ */ @@ -169,7 +169,7 @@ static void pulse_uncork_cb(pa_stream *pastream, int success, void *data) static void stream_uncork(SpicePulse *pulse, struct stream *s) { - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); pa_operation *o = NULL; if (s->cork_op) { @@ -214,7 +214,7 @@ static void pulse_cork_cb(pa_stream *pastream, int success, void *data) static void stream_cork(SpicePulse *pulse, struct stream *s) { - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); pa_operation *o = NULL; if (s->uncork_op) { @@ -234,7 +234,7 @@ static void stream_cork(SpicePulse *pulse, struct stream *s) static void stream_stop(SpicePulse *pulse, struct stream *s) { - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); if (pa_stream_disconnect(s->stream) < 0) { g_warning("pa_stream_disconnect() failed: %s", @@ -246,7 +246,7 @@ static void stream_stop(SpicePulse *pulse, struct stream *s) static void stream_state_callback(pa_stream *s, void *userdata) { - spice_pulse *p; + SpicePulsePrivate *p; p = SPICE_PULSE_GET_PRIVATE(userdata); g_return_if_fail(p != NULL); @@ -285,7 +285,7 @@ static void stream_underflow_cb(pa_stream *s, void *userdata) static void create_playback(SpicePulse *pulse) { - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); pa_stream_flags_t flags; pa_buffer_attr buffer_attr = { 0, }; @@ -318,7 +318,7 @@ static void playback_start(SpicePlaybackChannel *channel, gint format, gint chan gint frequency, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); pa_context_state_t state; g_return_if_fail(p != NULL); @@ -362,7 +362,7 @@ static void playback_data(SpicePlaybackChannel *channel, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); pa_stream_state_t state; if (!p->playback.stream) @@ -395,7 +395,7 @@ static void playback_data(SpicePlaybackChannel *channel, static void playback_stop(SpicePlaybackChannel *channel, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; SPICE_DEBUG("%s", __FUNCTION__); @@ -410,7 +410,7 @@ static void stream_update_timing_callback(pa_stream *s, int success, void *userd { pa_usec_t usec; int negative = 0; - spice_pulse *p; + SpicePulsePrivate *p; p = SPICE_PULSE_GET_PRIVATE(userdata); @@ -434,7 +434,7 @@ static void stream_update_timing_callback(pa_stream *s, int success, void *userd static void playback_get_delay(SpicePlaybackChannel *channel, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; if (p->playback.stream && pa_stream_get_state(p->playback.stream) == PA_STREAM_READY) { pa_operation *o; @@ -449,7 +449,7 @@ static void playback_get_delay(SpicePlaybackChannel *channel, gpointer data) static void stream_read_callback(pa_stream *s, size_t length, void *data) { SpicePulse *pulse = data; - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); g_return_if_fail(p != NULL); @@ -481,7 +481,7 @@ static void stream_read_callback(pa_stream *s, size_t length, void *data) static void create_record(SpicePulse *pulse) { - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); pa_buffer_attr buffer_attr = { 0, }; pa_stream_flags_t flags; @@ -513,7 +513,7 @@ static void record_start(SpiceRecordChannel *channel, gint format, gint channels gint frequency, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = SPICE_PULSE_GET_PRIVATE(pulse); + SpicePulsePrivate *p = SPICE_PULSE_GET_PRIVATE(pulse); pa_context_state_t state; p->record.started = TRUE; @@ -553,7 +553,7 @@ static void record_start(SpiceRecordChannel *channel, gint format, gint channels static void record_stop(SpiceRecordChannel *channel, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; SPICE_DEBUG("%s", __FUNCTION__); @@ -568,7 +568,7 @@ static void channel_event(SpiceChannel *channel, SpiceChannelEvent event, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; switch (event) { case SPICE_CHANNEL_OPENED: @@ -594,7 +594,7 @@ static void channel_event(SpiceChannel *channel, SpiceChannelEvent event, static void playback_volume_changed(GObject *object, GParamSpec *pspec, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; guint16 *volume; guint nchannels; pa_operation *op; @@ -630,7 +630,7 @@ static void playback_volume_changed(GObject *object, GParamSpec *pspec, gpointer static void playback_mute_changed(GObject *object, GParamSpec *pspec, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; gboolean mute; pa_operation *op; @@ -654,7 +654,7 @@ static void playback_mute_changed(GObject *object, GParamSpec *pspec, gpointer d static void record_mute_changed(GObject *object, GParamSpec *pspec, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; gboolean mute; pa_operation *op; @@ -678,7 +678,7 @@ static void record_mute_changed(GObject *object, GParamSpec *pspec, gpointer dat static void record_volume_changed(GObject *object, GParamSpec *pspec, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; guint16 *volume; guint nchannels; pa_operation *op; @@ -715,7 +715,7 @@ static void record_volume_changed(GObject *object, GParamSpec *pspec, gpointer d static void channel_new(SpiceSession *s, SpiceChannel *channel, gpointer data) { SpicePulse *pulse = data; - spice_pulse *p = pulse->priv; + SpicePulsePrivate *p = pulse->priv; if (SPICE_IS_PLAYBACK_CHANNEL(channel)) { g_return_if_fail(p->pchannel == NULL); @@ -756,7 +756,7 @@ static void channel_new(SpiceSession *s, SpiceChannel *channel, gpointer data) static void context_state_callback(pa_context *c, void *userdata) { - spice_pulse *p; + SpicePulsePrivate *p; p = SPICE_PULSE_GET_PRIVATE(userdata); g_return_if_fail(p != NULL); @@ -793,7 +793,7 @@ SpicePulse *spice_pulse_new(SpiceSession *session, GMainContext *context, const char *name) { SpicePulse *pulse; - spice_pulse *p; + SpicePulsePrivate *p; GList *list, *tmp; pulse = g_object_new(SPICE_TYPE_PULSE, NULL); diff --git a/gtk/spice-pulse.h b/gtk/spice-pulse.h index 0e484a9..819647e 100644 --- a/gtk/spice-pulse.h +++ b/gtk/spice-pulse.h @@ -33,11 +33,11 @@ G_BEGIN_DECLS typedef struct _SpicePulse SpicePulse; typedef struct _SpicePulseClass SpicePulseClass; -typedef struct spice_pulse spice_pulse; +typedef struct _SpicePulsePrivate SpicePulsePrivate; struct _SpicePulse { SpiceAudio parent; - spice_pulse *priv; + SpicePulsePrivate *priv; /* Do not add fields to this struct */ }; |