From: Siraaj Khandkar Date: Tue, 5 Mar 2019 13:28:14 +0000 (-0500) Subject: Shorten volume variable names X-Git-Url: https://git.xandkar.net/?a=commitdiff_plain;h=07d371033e9273977ae0b4557c10588a3556d9b6;p=khatus.git Shorten volume variable names --- diff --git a/x2/src/awk/exe/bar.awk b/x2/src/awk/exe/bar.awk index bd37305..6fd5a93 100644 --- a/x2/src/awk/exe/bar.awk +++ b/x2/src/awk/exe/bar.awk @@ -194,18 +194,18 @@ function bar_make_status_backlight_percent( src) { # Volume # ----------------------------------------------------------------------------- -function bar_make_status_volume_alsa_device(device, mu, vl, vr, show) { - cache_get(mu, "khatus_sensor_volume", "mute" Kfs device, 5) - cache_get(vl, "khatus_sensor_volume", "vol_left" Kfs device, 5) - cache_get(vr, "khatus_sensor_volume", "vol_right" Kfs device, 5) +function bar_make_status_volume_alsa_device(device, m, l, r, show) { + cache_get(m, "khatus_sensor_volume", "mute" Kfs device, 5) + cache_get(l, "khatus_sensor_volume", "vol_left" Kfs device, 5) + cache_get(r, "khatus_sensor_volume", "vol_right" Kfs device, 5) show = "--" - if (!mu["is_expired"] && !vl["is_expired"] && !vr["is_expired"]) { - if (mu["value"] == "yes") {show = "X"} - else if (mu["value"] == "no") {show = vl["value"] " " vr["value"]} + if (!m["is_expired"] && !l["is_expired"] && !r["is_expired"]) { + if (m["value"] == "yes") {show = "X"} + else if (m["value"] == "no") {show = l["value"] " " r["value"]} else { msg_out_log_error(\ "bar_make_status_volume_alsa_device: " device ". ", \ - "Unexpected value for 'mute' field: " mu["value"] \ + "Unexpected value for 'mute' field: " m["value"] \ ) } }