mirror of
https://github.com/alsa-project/alsa-utils
synced 2024-11-09 17:05:41 +01:00
Added toggle for cset
This commit is contained in:
parent
a23db635c9
commit
d205c38ea6
1 changed files with 4 additions and 0 deletions
|
@ -947,6 +947,10 @@ static int cset(int argc, char *argv[], int roflag)
|
|||
} else if (!strncasecmp(ptr, "yes", 3)) {
|
||||
tmp = 1;
|
||||
ptr += 3;
|
||||
} else if (!strncasecmp(ptr, "toggle", 6)) {
|
||||
snd_ctl_elem_value_get_boolean(control, idx, &tmp);
|
||||
tmp = tmp ? 0 : 1;
|
||||
ptr += 6;
|
||||
} else if (atoi(ptr)) {
|
||||
tmp = 1;
|
||||
while (isdigit(*ptr))
|
||||
|
|
Loading…
Reference in a new issue