diff options
author | Max Kellermann <max@duempel.org> | 2009-10-23 10:55:52 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2009-10-23 10:55:52 +0200 |
commit | e53ca368a5448291ca2783b8061727635084618f (patch) | |
tree | 596c18606cd386b580a23cc6d07cf121cca8db37 /src/output_internal.h | |
parent | c426a0bc5cc641ecd044c389f7180dad50a355bf (diff) |
output_plugin: added methods enable() and disable()
With these methods, an output plugin can allocate some global
resources only if it is actually enabled. The method enable() is
called after daemonization, which allows for more sophisticated
resource allocation during that method.
Diffstat (limited to 'src/output_internal.h')
-rw-r--r-- | src/output_internal.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/output_internal.h b/src/output_internal.h index f27a10ec7..0c25348a0 100644 --- a/src/output_internal.h +++ b/src/output_internal.h @@ -27,6 +27,8 @@ enum audio_output_command { AO_COMMAND_NONE = 0, + AO_COMMAND_ENABLE, + AO_COMMAND_DISABLE, AO_COMMAND_OPEN, /** @@ -71,6 +73,12 @@ struct audio_output { bool enabled; /** + * Is this device actually enabled, i.e. the "enable" method + * has succeeded? + */ + bool really_enabled; + + /** * Is the device (already) open and functional? * * This attribute may only be modified by the output thread. |