forked from external/yambar
module: remove ready_fd
All modules are expected to handle a call to content() after having been instantiated. I.e. modules *cannot* even expect run() to have started running.
This commit is contained in:
parent
65cfcfb2de
commit
acdeff3b6e
14 changed files with 27 additions and 66 deletions
|
@ -179,8 +179,6 @@ run(struct module_run_context *ctx)
|
|||
struct module *mod = ctx->module;
|
||||
struct private *m = mod->private;
|
||||
|
||||
module_signal_ready(ctx);
|
||||
|
||||
snd_mixer_t *handle;
|
||||
snd_mixer_open(&handle, 0);
|
||||
snd_mixer_attach(handle, m->card);
|
||||
|
@ -219,6 +217,8 @@ run(struct module_run_context *ctx)
|
|||
m->card, m->mixer, m->vol_min, m->vol_max, m->vol_cur,
|
||||
m->muted ? ", muted" : "");
|
||||
|
||||
mod->bar->refresh(mod->bar);
|
||||
|
||||
while (true) {
|
||||
int fd_count = snd_mixer_poll_descriptors_count(handle);
|
||||
assert(fd_count >= 1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue