aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Lezcano <daniel.lezcano@linaro.org>2011-05-24 15:27:49 +0200
committerDaniel Lezcano <daniel.lezcano@linaro.org>2011-05-24 15:27:49 +0200
commitdf51b2fe4486032edca1e8f64e4ab61c668e8691 (patch)
tree4ba393cd9398d9a054bfafa456896a3a680d0c9d
parent4b6690736b5d6efe367299df67d2e9b1741e78cf (diff)
downloadpowerdebug-df51b2fe4486032edca1e8f64e4ab61c668e8691.tar.gz
fix display when the default display is not the clock
Due to an internal error in clocks.c I am investigating, I am temporarly changing the test in the mainloop to have the clock being initialized when the option is set. Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
-rw-r--r--powerdebug.c44
1 files changed, 21 insertions, 23 deletions
diff --git a/powerdebug.c b/powerdebug.c
index 4d55f17..3e0272f 100644
--- a/powerdebug.c
+++ b/powerdebug.c
@@ -259,29 +259,27 @@ int mainloop(struct powerdebug_options *options,
options->verbose);
}
- if (options->selectedwindow == CLOCK) {
-
- if (options->clocks) {
- int hrow;
-
- create_selectedwindow(options->selectedwindow);
- if (!findparent_ncurses) {
- int command = 0;
-
- if (enter_hit)
- command = CLOCK_SELECTED;
- if (refreshwin)
- command = REFRESH_WINDOW;
- hrow = read_and_print_clock_info(
- options->verbose,
- highlighted_row,
- command);
- highlighted_row = hrow;
- enter_hit = false;
- } else
- find_parents_for_clock(clkname_str,
- enter_hit);
- }
+ if (options->clocks || options->selectedwindow == CLOCK) {
+
+ int hrow;
+
+ create_selectedwindow(options->selectedwindow);
+ if (!findparent_ncurses) {
+ int command = 0;
+
+ if (enter_hit)
+ command = CLOCK_SELECTED;
+ if (refreshwin)
+ command = REFRESH_WINDOW;
+ hrow = read_and_print_clock_info(
+ options->verbose,
+ highlighted_row,
+ command);
+ highlighted_row = hrow;
+ enter_hit = false;
+ } else
+ find_parents_for_clock(clkname_str,
+ enter_hit);
}
if (options->sensors || options->selectedwindow == SENSOR) {