X-Git-Url: https://git.wpitchoune.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fpsensor.h;h=fafcf3b5366006f273031b7f4d81f4a766fc605a;hb=1410f23801330c83c83caf21353860ff2bc18399;hp=f706bdefccbfef756287c1229aa9b5c05be5f790;hpb=b028afb4f41b141ee26e113b8b27f0d086dc8e1e;p=psensor.git diff --git a/src/lib/psensor.h b/src/lib/psensor.h index f706bde..fafcf3b 100644 --- a/src/lib/psensor.h +++ b/src/lib/psensor.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2010-2012 jeanfi@gmail.com + * Copyright (C) 2010-2013 jeanfi@gmail.com * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -84,7 +84,7 @@ struct psensor { struct color *color; /* Whether the graph sensor is displayed. */ - bool enabled; + bool graph_enabled; /* see psensor_type */ unsigned int type; @@ -118,7 +118,6 @@ struct psensor { #ifdef HAVE_ATASMART SkDisk *disk; #endif - char *url; bool appindicator_enabled; @@ -179,11 +178,13 @@ struct psensor **get_all_sensors(int use_libatasmart, int values_max_length); struct psensor **psensor_list_add(struct psensor **sensors, struct psensor *sensor); +struct psensor **psensor_list_copy(struct psensor **); + void psensor_set_current_value(struct psensor *sensor, double value); void psensor_set_current_measure(struct psensor *sensor, double value, struct timeval tv); -double psensor_get_current_value(struct psensor *sensor); +double psensor_get_current_value(const struct psensor *); struct measure *psensor_get_current_measure(struct psensor *sensor); @@ -205,6 +206,7 @@ double get_max_value(struct psensor **sensors, int type); double celcius_to_fahrenheit(double c); double fahrenheit_to_celcius(double c); +char *psensor_current_value_to_str(const struct psensor *, unsigned int); void psensor_log_measures(struct psensor **sensors);