aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author05356787 <05356787@localhost.localdomain>2008-10-30 09:54:35 -0200
committer05356787 <05356787@localhost.localdomain>2008-10-30 09:54:35 -0200
commit0fa6067111faa2ce69ed8275b06ef8d5ab669a56 (patch)
tree73fccd7cbb5c0db2d42390abae8964ab66ebe621
parentff03a5d1bf53392f324e4653764b3079bd94c4bf (diff)
Cleanups
-rw-r--r--hardinfo2/benchmark.c33
-rw-r--r--hardinfo2/shell.c3
2 files changed, 20 insertions, 16 deletions
diff --git a/hardinfo2/benchmark.c b/hardinfo2/benchmark.c
index b1438fce..79d3d2d4 100644
--- a/hardinfo2/benchmark.c
+++ b/hardinfo2/benchmark.c
@@ -150,7 +150,7 @@ static gchar *__benchmark_include_results(gdouble result,
{
GKeyFile *conf;
gchar **machines;
- gchar *path, *results = g_strdup("");
+ gchar *path, *results = g_strdup(""), *return_value, *processor_frequency;
int i;
conf = g_key_file_new();
@@ -178,22 +178,25 @@ static gchar *__benchmark_include_results(gdouble result,
g_free(path);
g_key_file_free(conf);
- DEBUG("results = %s", results);
-
- return g_strdup_printf("[$ShellParam$]\n"
- "Zebra=1\n"
- "OrderType=%d\n"
- "ViewType=3\n"
- "ColumnTitle$Extra1=CPU Clock\n"
- "ColumnTitle$Extra2=Memory\n"
- "ColumnTitle$Progress=Results\n"
- "ColumnTitle$TextValue=CPU\n"
- "ShowColumnHeaders=true\n"
- "[%s]\n"
- "<big><b>This Machine</b></big>=%.3f|extra1|extra2\n"
- "%s", order_type, benchmark, result, results);
+ processor_frequency = module_call_method("devices::getProcessorFrequency");
+ return_value = g_strdup_printf("[$ShellParam$]\n"
+ "Zebra=1\n"
+ "OrderType=%d\n"
+ "ViewType=3\n"
+ "ColumnTitle$Extra1=CPU Clock\n"
+ "ColumnTitle$Extra2=Memory\n"
+ "ColumnTitle$Progress=Results\n"
+ "ColumnTitle$TextValue=CPU\n"
+ "ShowColumnHeaders=true\n"
+ "[%s]\n"
+ "<big><b>This Machine</b></big>=%.3f|%s MHz|extra2\n"
+ "%s", order_type, benchmark, result, processor_frequency, results);
+ g_free(processor_frequency);
+ return return_value;
}
+
+
static gchar *benchmark_include_results_reverse(gdouble result,
const gchar * benchmark)
{
diff --git a/hardinfo2/shell.c b/hardinfo2/shell.c
index 2a61246b..6d0508c7 100644
--- a/hardinfo2/shell.c
+++ b/hardinfo2/shell.c
@@ -1107,9 +1107,10 @@ module_selected_show_info(ShellModuleEntry * entry, gboolean reload)
store = GTK_TREE_STORE(shell->info->model);
+ gdk_window_freeze_updates(shell->window->window);
+
g_object_ref(shell->info->model);
gtk_tree_view_set_model(GTK_TREE_VIEW(shell->info->view), NULL);
- gdk_window_freeze_updates(shell->window->window);
gtk_tree_store_clear(store);