Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/aiomixer aiomixer: display the unit type for value c...



details:   https://anonhg.NetBSD.org/src/rev/e5881658a0ad
branches:  trunk
changeset: 983173:e5881658a0ad
user:      nia <nia%NetBSD.org@localhost>
date:      Fri May 07 19:37:03 2021 +0000

description:
aiomixer: display the unit type for value controls

diffstat:

 usr.bin/aiomixer/draw.c |  8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diffs (22 lines):

diff -r d76b31851cfa -r e5881658a0ad usr.bin/aiomixer/draw.c
--- a/usr.bin/aiomixer/draw.c   Fri May 07 17:47:30 2021 +0000
+++ b/usr.bin/aiomixer/draw.c   Fri May 07 19:37:03 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: draw.c,v 1.2 2021/05/07 17:47:30 nia Exp $ */
+/* $NetBSD: draw.c,v 1.3 2021/05/07 19:37:03 nia Exp $ */
 /*-
  * Copyright (c) 2021 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -93,7 +93,11 @@
        wclear(control->widgetpad);
        if (selected)
                wattron(control->widgetpad, A_STANDOUT);
-       wprintw(control->widgetpad, "%s\n", control->info.label.name);
+       if (value.type == AUDIO_MIXER_VALUE)
+               wprintw(control->widgetpad, "%s (%s)\n",
+                   control->info.label.name, control->info.un.v.units.name);
+       else
+               wprintw(control->widgetpad, "%s\n", control->info.label.name);
        if (selected)
                wattroff(control->widgetpad, A_STANDOUT);
 



Home | Main Index | Thread Index | Old Index