diff --git a/AUTHORS b/AUTHORS index 02539a07..80d98136 100644 --- a/AUTHORS +++ b/AUTHORS @@ -210,8 +210,10 @@ Thomas Cort Toni exec*/tail/head output evalution -Toni Spets hifi +Toni Spets hifi OpenBSD support + Linux wifi code + RSS code (created with Mikko Sysikaski) tyir MPD features patch 1319461 diff --git a/doc/variables.xml b/doc/variables.xml index 51729a02..1d92e25d 100644 --- a/doc/variables.xml +++ b/doc/variables.xml @@ -559,96 +559,6 @@ - - - - - - - Wireless access point ESSID (Linux only) - - - - - - - - - - Wireless mode (Managed/Ad-Hoc/Master) (Linux only) - - - - - - - - - - Wireless bitrate (ie 11 Mb/s) (Linux only) - - - - - - - - - - Wireless access point MAC address (Linux only) - - - - - - - - - - Wireless link quality (Linux only) - - - - - - - - - - Wireless link quality maximum value (Linux only) - - - - - - - - - - Wireless link quality in percents (Linux only) - - - - - - - - - - Wireless link quality bar (Linux only) - - - - - - - - - - Download and parse RSS feeds. Action may be one of the following: feed_title, item_title (with num par), item_desc (with num par) and item_titles. - - - @@ -1149,16 +1059,6 @@ - - - - - - - Get the link status for wireless connections - - - @@ -1621,6 +1521,16 @@ + + + + + + + Download and parse RSS feeds. Action may be one of the following: feed_title, item_title (with num par), item_desc (with num par) and item_titles. + + + @@ -1803,6 +1713,86 @@ + + + + + + + Wireless access point ESSID (Linux only) + + + + + + + + + + Wireless mode (Managed/Ad-Hoc/Master) (Linux only) + + + + + + + + + + Wireless bitrate (ie 11 Mb/s) (Linux only) + + + + + + + + + + Wireless access point MAC address (Linux only) + + + + + + + + + + Wireless link quality (Linux only) + + + + + + + + + + Wireless link quality maximum value (Linux only) + + + + + + + + + + Wireless link quality in percents (Linux only) + + + + + + + + + + Wireless link quality bar (Linux only) + + + diff --git a/src/conky.c b/src/conky.c index 9dbc8517..77423f24 100644 --- a/src/conky.c +++ b/src/conky.c @@ -3584,10 +3584,12 @@ static void generate_text_internal(char *p, int p_max_size, struct text_object * snprintf(p, 4, "%d ", obj->data.net->link_qual_max); } OBJ(wireless_link_qual_perc) { - if (!use_spacer) - snprintf(p, p_max_size, "%.0f%%", (double)obj->data.net->link_qual / obj->data.net->link_qual_max * 100); - else - snprintf(p, 5, "%.0f%% ", (double)obj->data.net->link_qual / obj->data.net->link_qual_max * 100); + if(obj->data.net->link_qual_max > 0) { + if (!use_spacer) + snprintf(p, p_max_size, "%.0f%%", (double)obj->data.net->link_qual / obj->data.net->link_qual_max * 100); + else + snprintf(p, 5, "%.0f%% ", (double)obj->data.net->link_qual / obj->data.net->link_qual_max * 100); + } else snprintf(p, p_max_size, "unk"); } OBJ(wireless_link_bar) { new_bar(p, obj->a, obj->b, ((double)obj->data.net->link_qual/obj->data.net->link_qual_max)*255.0); diff --git a/src/linux.c b/src/linux.c index 457a4880..6b4c1b13 100644 --- a/src/linux.c +++ b/src/linux.c @@ -8,6 +8,7 @@ * Please see COPYING for details * * Copyright (c) 2004, Hannu Saransaari and Lauri Hakkarainen + * Copyright (c) 2007 Toni Spets * Copyright (c) 2005-2007 Brenden Matthews, Philip Kovacs, et. al. (see AUTHORS) * All rights reserved. *