summaryrefslogtreecommitdiff
path: root/backends/pulse/pulse-connection.h
diff options
context:
space:
mode:
authorMichal Ratajsky <[email protected]>2014-06-20 00:12:40 +0200
committerMichal Ratajsky <[email protected]>2014-06-20 00:12:40 +0200
commit6be9a89195e0d3bf8408cea661f22cb97b638f24 (patch)
tree745cfec763facc62b6c3bc51cd246e5cad4d9f68 /backends/pulse/pulse-connection.h
parenta2290d5e13ccee88fd9ae66a3895eb4da646f81f (diff)
downloadlibmatemixer-6be9a89195e0d3bf8408cea661f22cb97b638f24.tar.bz2
libmatemixer-6be9a89195e0d3bf8408cea661f22cb97b638f24.tar.xz
Pulse and API updates, fixes
Diffstat (limited to 'backends/pulse/pulse-connection.h')
-rw-r--r--backends/pulse/pulse-connection.h204
1 files changed, 106 insertions, 98 deletions
diff --git a/backends/pulse/pulse-connection.h b/backends/pulse/pulse-connection.h
index 922b65a..b3f01b7 100644
--- a/backends/pulse/pulse-connection.h
+++ b/backends/pulse/pulse-connection.h
@@ -24,6 +24,7 @@
#include <pulse/pulseaudio.h>
#include "pulse-enums.h"
+#include "pulse-monitor.h"
G_BEGIN_DECLS
@@ -36,7 +37,7 @@ G_BEGIN_DECLS
#define PULSE_CONNECTION_CLASS(k) \
(G_TYPE_CHECK_CLASS_CAST ((k), PULSE_TYPE_CONNECTION, PulseConnectionClass))
#define PULSE_IS_CONNECTION_CLASS(k) \
- (G_TYPE_CLASS_CHECK_CLASS_TYPE ((k), PULSE_TYPE_CONNECTION))
+ (G_TYPE_CHECK_CLASS_TYPE ((k), PULSE_TYPE_CONNECTION))
#define PULSE_CONNECTION_GET_CLASS(o) \
(G_TYPE_INSTANCE_GET_CLASS ((o), PULSE_TYPE_CONNECTION, PulseConnectionClass))
@@ -48,110 +49,117 @@ struct _PulseConnection
{
GObject parent;
+ /*< private >*/
PulseConnectionPrivate *priv;
};
struct _PulseConnectionClass
{
- GObjectClass parent;
-
- void (*server_info) (PulseConnection *connection,
- const pa_server_info *info);
- void (*card_info) (PulseConnection *connection,
- const pa_card_info *info);
- void (*card_removed) (PulseConnection *connection,
- guint32 index);
- void (*sink_info) (PulseConnection *connection,
- const pa_sink_info *info);
- void (*sink_removed) (PulseConnection *connection,
- guint32 index);
- void (*sink_input_info) (PulseConnection *connection,
- const pa_sink_input_info *info);
- void (*sink_input_removed) (PulseConnection *connection,
- guint32 index);
- void (*source_info) (PulseConnection *connection,
- const pa_source_info *info);
- void (*source_removed) (PulseConnection *connection,
- guint32 index);
- void (*source_output_info) (PulseConnection *connection,
- const pa_source_output_info *info);
- void (*source_output_removed) (PulseConnection *connection,
- guint32 index);
+ GObjectClass parent_class;
+
+ /* Signals */
+ void (*server_info) (PulseConnection *connection,
+ const pa_server_info *info);
+ void (*card_info) (PulseConnection *connection,
+ const pa_card_info *info);
+ void (*card_removed) (PulseConnection *connection,
+ guint32 index);
+ void (*sink_info) (PulseConnection *connection,
+ const pa_sink_info *info);
+ void (*sink_removed) (PulseConnection *connection,
+ guint32 index);
+ void (*sink_input_info) (PulseConnection *connection,
+ const pa_sink_input_info *info);
+ void (*sink_input_removed) (PulseConnection *connection,
+ guint32 index);
+ void (*source_info) (PulseConnection *connection,
+ const pa_source_info *info);
+ void (*source_removed) (PulseConnection *connection,
+ guint32 index);
+ void (*source_output_info) (PulseConnection *connection,
+ const pa_source_output_info *info);
+ void (*source_output_removed) (PulseConnection *connection,
+ guint32 index);
};
-GType pulse_connection_get_type (void) G_GNUC_CONST;
-
-PulseConnection *pulse_connection_new (const gchar *app_name,
- const gchar *app_id,
- const gchar *app_version,
- const gchar *app_icon,
- const gchar *server_address);
-
-gboolean pulse_connection_connect (PulseConnection *connection);
-void pulse_connection_disconnect (PulseConnection *connection);
-
-PulseConnectionState pulse_connection_get_state (PulseConnection *connection);
-
-gboolean pulse_connection_set_default_sink (PulseConnection *connection,
- const gchar *name);
-
-gboolean pulse_connection_set_default_source (PulseConnection *connection,
- const gchar *name);
-
-gboolean pulse_connection_set_card_profile (PulseConnection *connection,
- const gchar *device,
- const gchar *profile);
-
-gboolean pulse_connection_set_sink_mute (PulseConnection *connection,
- guint32 index,
- gboolean mute);
-gboolean pulse_connection_set_sink_volume (PulseConnection *connection,
- guint32 index,
- const pa_cvolume *volume);
-gboolean pulse_connection_set_sink_port (PulseConnection *connection,
- guint32 index,
- const gchar *port);
-
-gboolean pulse_connection_set_sink_input_mute (PulseConnection *connection,
- guint32 index,
- gboolean mute);
-
-gboolean pulse_connection_set_sink_input_volume (PulseConnection *connection,
- guint32 index,
- const pa_cvolume *volume);
-
-
-gboolean pulse_connection_set_source_mute (PulseConnection *connection,
- guint32 index,
- gboolean mute);
-gboolean pulse_connection_set_source_volume (PulseConnection *connection,
- guint32 index,
- const pa_cvolume *volume);
-gboolean pulse_connection_set_source_port (PulseConnection *connection,
- guint32 index,
- const gchar *port);
-
-gboolean pulse_connection_set_source_output_mute (PulseConnection *connection,
- guint32 index,
- gboolean mute);
-
-gboolean pulse_connection_set_source_output_volume (PulseConnection *connection,
- guint32 index,
- const pa_cvolume *volume);
-
-gboolean pulse_connection_move_sink_input (PulseConnection *connection,
- guint32 index,
- guint32 sink_index);
-
-gboolean pulse_connection_move_source_output (PulseConnection *connection,
- guint32 index,
- guint32 source_index);
-
-gboolean pulse_connection_kill_sink_input (PulseConnection *connection,
- guint32 index);
-
-gboolean pulse_connection_kill_source_output (PulseConnection *connection,
- guint32 index);
+GType pulse_connection_get_type (void) G_GNUC_CONST;
+
+PulseConnection * pulse_connection_new (const gchar *app_name,
+ const gchar *app_id,
+ const gchar *app_version,
+ const gchar *app_icon,
+ const gchar *server_address);
+
+gboolean pulse_connection_connect (PulseConnection *connection);
+void pulse_connection_disconnect (PulseConnection *connection);
+
+PulseConnectionState pulse_connection_get_state (PulseConnection *connection);
+
+PulseMonitor * pulse_connection_create_monitor (PulseConnection *connection,
+ guint32 index_source,
+ guint32 index_sink_input);
+
+gboolean pulse_connection_set_default_sink (PulseConnection *connection,
+ const gchar *name);
+gboolean pulse_connection_set_default_source (PulseConnection *connection,
+ const gchar *name);
+
+gboolean pulse_connection_set_card_profile (PulseConnection *connection,
+ const gchar *device,
+ const gchar *profile);
+
+gboolean pulse_connection_set_sink_mute (PulseConnection *connection,
+ guint32 index,
+ gboolean mute);
+gboolean pulse_connection_set_sink_volume (PulseConnection *connection,
+ guint32 index,
+ const pa_cvolume *volume);
+gboolean pulse_connection_set_sink_port (PulseConnection *connection,
+ guint32 index,
+ const gchar *port);
+
+gboolean pulse_connection_set_sink_input_mute (PulseConnection *connection,
+ guint32 index,
+ gboolean mute);
+gboolean pulse_connection_set_sink_input_volume (PulseConnection *connection,
+ guint32 index,
+ const pa_cvolume *volume);
+
+gboolean pulse_connection_set_source_mute (PulseConnection *connection,
+ guint32 index,
+ gboolean mute);
+gboolean pulse_connection_set_source_volume (PulseConnection *connection,
+ guint32 index,
+ const pa_cvolume *volume);
+gboolean pulse_connection_set_source_port (PulseConnection *connection,
+ guint32 index,
+ const gchar *port);
+
+gboolean pulse_connection_set_source_output_mute (PulseConnection *connection,
+ guint32 index,
+ gboolean mute);
+gboolean pulse_connection_set_source_output_volume (PulseConnection *connection,
+ guint32 index,
+ const pa_cvolume *volume);
+
+gboolean pulse_connection_suspend_sink (PulseConnection *connection,
+ guint32 index,
+ gboolean suspend);
+gboolean pulse_connection_suspend_source (PulseConnection *connection,
+ guint32 index,
+ gboolean suspend);
+
+gboolean pulse_connection_move_sink_input (PulseConnection *connection,
+ guint32 index,
+ guint32 sink_index);
+gboolean pulse_connection_move_source_output (PulseConnection *connection,
+ guint32 index,
+ guint32 source_index);
+
+gboolean pulse_connection_kill_sink_input (PulseConnection *connection,
+ guint32 index);
+gboolean pulse_connection_kill_source_output (PulseConnection *connection,
+ guint32 index);
G_END_DECLS