aboutsummaryrefslogtreecommitdiffstats
path: root/src/MixerPlugin.hxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-08-10 18:02:44 +0200
committerMax Kellermann <max@duempel.org>2013-09-04 18:14:22 +0200
commit29030b54c98b0aee65fbc10ebf7ba36bed98c02c (patch)
tree79766830b55ebca38ddbce84d8d548227eedb69e /src/MixerPlugin.hxx
parentc9fcc7f14860777458153eb2d13c773ccfa1daa2 (diff)
downloadmpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.tar.gz
mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.tar.xz
mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.zip
util/Error: new error passing library
Replaces GLib's GError.
Diffstat (limited to 'src/MixerPlugin.hxx')
-rw-r--r--src/MixerPlugin.hxx13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/MixerPlugin.hxx b/src/MixerPlugin.hxx
index e80ae094e..4dd8969b9 100644
--- a/src/MixerPlugin.hxx
+++ b/src/MixerPlugin.hxx
@@ -27,10 +27,9 @@
#ifndef MPD_MIXER_PLUGIN_HXX
#define MPD_MIXER_PLUGIN_HXX
-#include "gerror.h"
-
struct config_param;
class Mixer;
+class Error;
struct mixer_plugin {
/**
@@ -43,7 +42,7 @@ struct mixer_plugin {
* @return a mixer object, or NULL on error
*/
Mixer *(*init)(void *ao, const config_param &param,
- GError **error_r);
+ Error &error);
/**
* Finish and free mixer data
@@ -57,7 +56,7 @@ struct mixer_plugin {
* NULL to ignore errors
* @return true on success, false on error
*/
- bool (*open)(Mixer *data, GError **error_r);
+ bool (*open)(Mixer *data, Error &error);
/**
* Close mixer device
@@ -70,9 +69,9 @@ struct mixer_plugin {
* @param error_r location to store the error occurring, or
* NULL to ignore errors
* @return the current volume (0..100 including) or -1 if
- * unavailable or on error (error_r set, mixer will be closed)
+ * unavailable or on error (error set, mixer will be closed)
*/
- int (*get_volume)(Mixer *mixer, GError **error_r);
+ int (*get_volume)(Mixer *mixer, Error &error);
/**
* Sets the volume.
@@ -83,7 +82,7 @@ struct mixer_plugin {
* @return true on success, false on error
*/
bool (*set_volume)(Mixer *mixer, unsigned volume,
- GError **error_r);
+ Error &error);
/**
* If true, then the mixer is automatically opened, even if