aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid <dbphillipsnz@gmail.com>2014-02-14 21:19:10 +1300
committerDavid <dbphillipsnz@gmail.com>2014-02-14 21:19:10 +1300
commit32ee4028069ff3317e91bbed9edad48b67c64881 (patch)
tree29b545302eecbd1158b4abbee5b549960f10b9a9
parent6173eb0eec3d1a0fbf5436e15cb314468f3f6c9c (diff)
downloadparamano-32ee4028069ff3317e91bbed9edad48b67c64881.tar.xz
Code cleanup
-rw-r--r--src/config.h62
-rw-r--r--src/config_file.c2
-rw-r--r--src/config_file.h2
-rw-r--r--src/defaults.c5
-rw-r--r--src/defaults.h2
-rw-r--r--src/getbat.c2
-rw-r--r--src/getbat.h10
-rw-r--r--src/getgov.c1
-rw-r--r--src/trayfreq.c4
-rw-r--r--src/trayfreq_set.c2
-rw-r--r--src/trayfreq_set_interface.c2
-rw-r--r--src/trayfreq_set_interface.h2
-rw-r--r--src/utilities.c2
-rw-r--r--src/utilities.h2
14 files changed, 15 insertions, 85 deletions
diff --git a/src/config.h b/src/config.h
deleted file mode 100644
index c4da35c..0000000
--- a/src/config.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/* src/config.h. Generated from config.h.in by configure. */
-/* src/config.h.in. Generated from configure.ac by autoheader. */
-
-/* Define to 1 if you have the <inttypes.h> header file. */
-#define HAVE_INTTYPES_H 1
-
-/* Define to 1 if you have the <memory.h> header file. */
-#define HAVE_MEMORY_H 1
-
-/* Define to 1 if you have the <stdint.h> header file. */
-#define HAVE_STDINT_H 1
-
-/* Define to 1 if you have the <stdlib.h> header file. */
-#define HAVE_STDLIB_H 1
-
-/* Define to 1 if you have the <strings.h> header file. */
-#define HAVE_STRINGS_H 1
-
-/* Define to 1 if you have the <string.h> header file. */
-#define HAVE_STRING_H 1
-
-/* Define to 1 if you have the <sys/stat.h> header file. */
-#define HAVE_SYS_STAT_H 1
-
-/* Define to 1 if you have the <sys/types.h> header file. */
-#define HAVE_SYS_TYPES_H 1
-
-/* Define to 1 if you have the <unistd.h> header file. */
-#define HAVE_UNISTD_H 1
-
-/* Define to 1 if your C compiler doesn't accept -c and -o together. */
-/* #undef NO_MINUS_C_MINUS_O */
-
-/* Name of package */
-#define PACKAGE "trayfreq"
-
-/* Define to the address where bug reports for this package should be sent. */
-#define PACKAGE_BUGREPORT ""
-
-/* Define to the full name of this package. */
-#define PACKAGE_NAME "trayfreq"
-
-/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "trayfreq 0.2.x-dev2"
-
-/* Define to the one symbol short name of this package. */
-#define PACKAGE_TARNAME "trayfreq"
-
-/* Define to the home page for this package. */
-#define PACKAGE_URL ""
-
-/* Define to the version of this package. */
-#define PACKAGE_VERSION "0.2.x-dev2"
-
-/* "" */
-#define PREFIX "NONE"
-
-/* Define to 1 if you have the ANSI C header files. */
-#define STDC_HEADERS 1
-
-/* Version number of package */
-#define VERSION "0.2.x-dev2"
diff --git a/src/config_file.c b/src/config_file.c
index 862a3c6..73ac321 100644
--- a/src/config_file.c
+++ b/src/config_file.c
@@ -36,4 +36,4 @@ void config_close(struct config_file* config_file)
gchar* config_get_key(struct config_file* config_file, const gchar* group_name, const gchar* key_name)
{
return g_key_file_get_value(config_file->key_file, group_name, key_name, NULL);
-}
+} \ No newline at end of file
diff --git a/src/config_file.h b/src/config_file.h
index 0ce78bb..d478e64 100644
--- a/src/config_file.h
+++ b/src/config_file.h
@@ -30,4 +30,4 @@ gboolean config_open(struct config_file* config_file);
void config_close(struct config_file* config_file);
gchar* config_get_key(struct config_file* config_file, const gchar* group_name, const gchar* key_name);
-#endif
+#endif \ No newline at end of file
diff --git a/src/defaults.c b/src/defaults.c
index 097f7ea..e409480 100644
--- a/src/defaults.c
+++ b/src/defaults.c
@@ -23,9 +23,6 @@ gchar* default_prog = NULL;
gchar* default_bat_gov = NULL;
gchar* default_ac_gov = NULL;
-
-/* to do */
-
gchar* def_get_gov()
{
return default_gov;
@@ -74,4 +71,4 @@ void def_set_bat_gov(gchar* bat_gov)
void def_set_ac_gov(gchar* ac_gov)
{
default_ac_gov = ac_gov;
-}
+} \ No newline at end of file
diff --git a/src/defaults.h b/src/defaults.h
index 157b3a3..c6d1b87 100644
--- a/src/defaults.h
+++ b/src/defaults.h
@@ -31,4 +31,4 @@ void def_set_prog(gchar* prog);
void def_set_bat_gov(gchar* bat_gov);
void def_set_ac_gov(gchar* ac_gov);
-#endif
+#endif \ No newline at end of file
diff --git a/src/getbat.c b/src/getbat.c
index ac6a7dd..363e725 100644
--- a/src/getbat.c
+++ b/src/getbat.c
@@ -130,8 +130,6 @@ gboolean gb_init()
return TRUE;
}
-/* To do: replace with '#define's */
-
gint gb_current_rate()
{
return get_int_value_from_file(CURRENT_PATH);
diff --git a/src/getbat.h b/src/getbat.h
index 219d1b6..6dcc3c9 100644
--- a/src/getbat.h
+++ b/src/getbat.h
@@ -27,11 +27,11 @@ gboolean gb_discharging();
gboolean gb_charged();
gboolean gb_charging();
gint gb_number();
-gint gb_max_capacity();
-gint gb_warn_capacity();
-gint gb_low_capacity();
+//gint gb_max_capacity();
+//gint gb_warn_capacity();
+//gint gb_low_capacity();
gint gb_percent();
-void gb_discharge_time(gchar* time);
-void gb_charge_time(gchar* time);
+//void gb_time(gchar* time);
+//void gb_charge_time(gchar* time);
#endif \ No newline at end of file
diff --git a/src/getgov.c b/src/getgov.c
index df723a9..1a7c913 100644
--- a/src/getgov.c
+++ b/src/getgov.c
@@ -96,7 +96,6 @@ int gg_available(int core, char* out, int size)
return 0;
}
-/* to do */
char* gg_gov(int core, int index)
{
return AVAILABLE_GOVERNORS[core][index];
diff --git a/src/trayfreq.c b/src/trayfreq.c
index 3d5b362..6ee439a 100644
--- a/src/trayfreq.c
+++ b/src/trayfreq.c
@@ -118,6 +118,4 @@ int main(int argc, char** argv)
gtk_main();
return 0;
-}
-
-
+} \ No newline at end of file
diff --git a/src/trayfreq_set.c b/src/trayfreq_set.c
index 1719447..5a5caf9 100644
--- a/src/trayfreq_set.c
+++ b/src/trayfreq_set.c
@@ -117,4 +117,4 @@ int main(int argc, char *argv[])
printf("Use -g to set the governor or -f to set the frequency.\n");
}
return 0;
-}
+} \ No newline at end of file
diff --git a/src/trayfreq_set_interface.c b/src/trayfreq_set_interface.c
index 81c9299..f3731b6 100644
--- a/src/trayfreq_set_interface.c
+++ b/src/trayfreq_set_interface.c
@@ -42,4 +42,4 @@ void si_freq(int freq, int core)
gchar* cmd = g_strconcat(util_get_prefix(), "/bin/trayfreq-set -f ", freqstr, " -c ", corestr, NULL);
system(cmd);
g_free(cmd);
-}
+} \ No newline at end of file
diff --git a/src/trayfreq_set_interface.h b/src/trayfreq_set_interface.h
index 64394aa..78398cc 100644
--- a/src/trayfreq_set_interface.h
+++ b/src/trayfreq_set_interface.h
@@ -21,4 +21,4 @@
void si_gov(char* gov, int core);
void si_freq(int freq, int core);
-#endif
+#endif \ No newline at end of file
diff --git a/src/utilities.c b/src/utilities.c
index 8e3e998..82b44c8 100644
--- a/src/utilities.c
+++ b/src/utilities.c
@@ -34,4 +34,4 @@ const gchar* util_get_prefix()
return "/usr";
else
return PREFIX;
-}
+} \ No newline at end of file
diff --git a/src/utilities.h b/src/utilities.h
index ae47d01..7decd6f 100644
--- a/src/utilities.h
+++ b/src/utilities.h
@@ -25,4 +25,4 @@
gint util_compare_gdouble(gdouble a, gdouble b);
const gchar* util_get_prefix();
-#endif
+#endif \ No newline at end of file