Amit Arora | 39f2954 | 2010-09-14 12:03:22 +0530 | [diff] [blame] | 1 | /******************************************************************************* |
Amit Kucheria | c0e17fc | 2011-01-17 09:35:52 +0200 | [diff] [blame] | 2 | * Copyright (C) 2010, Linaro Limited. |
Amit Arora | 39f2954 | 2010-09-14 12:03:22 +0530 | [diff] [blame] | 3 | * |
| 4 | * This file is part of PowerDebug. |
| 5 | * |
| 6 | * All rights reserved. This program and the accompanying materials |
| 7 | * are made available under the terms of the Eclipse Public License v1.0 |
| 8 | * which accompanies this distribution, and is available at |
| 9 | * http://www.eclipse.org/legal/epl-v10.html |
| 10 | * |
| 11 | * Contributors: |
| 12 | * Amit Arora <amit.arora@linaro.org> (IBM Corporation) |
| 13 | * - initial API and implementation |
| 14 | *******************************************************************************/ |
| 15 | |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 16 | #include "powerdebug.h" |
Amit Arora | 1755278 | 2010-12-02 12:23:14 +0530 | [diff] [blame] | 17 | #include "regulator.h" |
Amit Arora | ed3e565 | 2010-10-27 12:02:53 +0530 | [diff] [blame] | 18 | #include "display.h" |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 19 | |
| 20 | #define print(w, x, y, fmt, args...) do { mvwprintw(w, y, x, fmt, ##args); } while (0) |
| 21 | #define NUM_FOOTER_ITEMS 5 |
| 22 | |
| 23 | static WINDOW *header_win; |
| 24 | static WINDOW *regulator_win; |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 25 | static WINDOW *clock_win; |
| 26 | static WINDOW *sensor_win; |
Amit Arora | c93e071 | 2010-10-07 13:51:53 +0530 | [diff] [blame] | 27 | static WINDOW *selected_win; |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 28 | static WINDOW *footer_win; |
| 29 | |
| 30 | int maxx, maxy; |
| 31 | char footer_items[NUM_FOOTER_ITEMS][64]; |
| 32 | |
Daniel Lezcano | d5a2c6d | 2011-03-23 14:37:38 +0100 | [diff] [blame] | 33 | static char *win_names[TOTAL_FEATURE_WINS] = { |
| 34 | "Clocks", |
| 35 | "Regulators", |
| 36 | "Sensors" |
| 37 | }; |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 38 | |
Amit Arora | c93e071 | 2010-10-07 13:51:53 +0530 | [diff] [blame] | 39 | /* "all" : Kill header and footer windows too ? */ |
| 40 | void killall_windows(int all) |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 41 | { |
Amit Arora | c93e071 | 2010-10-07 13:51:53 +0530 | [diff] [blame] | 42 | if (all && header_win) { |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 43 | delwin(header_win); |
| 44 | header_win = NULL; |
| 45 | } |
| 46 | if (regulator_win) { |
| 47 | delwin(regulator_win); |
| 48 | regulator_win = NULL; |
| 49 | } |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 50 | if (clock_win) { |
| 51 | delwin(clock_win); |
| 52 | clock_win = NULL; |
| 53 | } |
| 54 | if (sensor_win) { |
| 55 | delwin(sensor_win); |
| 56 | sensor_win = NULL; |
| 57 | } |
Amit Arora | c93e071 | 2010-10-07 13:51:53 +0530 | [diff] [blame] | 58 | if (all && footer_win) { |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 59 | delwin(footer_win); |
| 60 | footer_win = NULL; |
| 61 | } |
| 62 | } |
| 63 | |
Daniel Lezcano | 3abd8b1 | 2011-03-26 22:06:15 +0100 | [diff] [blame^] | 64 | static void display_fini(void) |
| 65 | { |
| 66 | endwin(); |
| 67 | } |
| 68 | |
Daniel Lezcano | 192c1d2 | 2011-03-26 22:06:14 +0100 | [diff] [blame] | 69 | void display_init(void) |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 70 | { |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 71 | initscr(); |
| 72 | start_color(); |
| 73 | keypad(stdscr, TRUE); |
| 74 | noecho(); |
| 75 | cbreak(); |
| 76 | curs_set(0); |
| 77 | nonl(); |
| 78 | use_default_colors(); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 79 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 80 | init_pair(PT_COLOR_DEFAULT, COLOR_WHITE, COLOR_BLACK); |
| 81 | init_pair(PT_COLOR_ERROR, COLOR_BLACK, COLOR_RED); |
Amit Kucheria | b85e5d5 | 2011-01-12 10:55:24 -0600 | [diff] [blame] | 82 | init_pair(PT_COLOR_HEADER_BAR, COLOR_WHITE, COLOR_BLACK); |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 83 | init_pair(PT_COLOR_YELLOW, COLOR_WHITE, COLOR_YELLOW); |
| 84 | init_pair(PT_COLOR_GREEN, COLOR_WHITE, COLOR_GREEN); |
| 85 | init_pair(PT_COLOR_BRIGHT, COLOR_WHITE, COLOR_BLACK); |
| 86 | init_pair(PT_COLOR_BLUE, COLOR_WHITE, COLOR_BLUE); |
| 87 | init_pair(PT_COLOR_RED, COLOR_WHITE, COLOR_RED); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 88 | |
Daniel Lezcano | 3abd8b1 | 2011-03-26 22:06:15 +0100 | [diff] [blame^] | 89 | atexit(display_fini); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 90 | } |
| 91 | |
Daniel Lezcano | 558a6d5 | 2011-03-23 14:37:41 +0100 | [diff] [blame] | 92 | void create_windows(int selectedwindow) |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 93 | { |
| 94 | |
| 95 | getmaxyx(stdscr, maxy, maxx); |
Amit Arora | c93e071 | 2010-10-07 13:51:53 +0530 | [diff] [blame] | 96 | killall_windows(1); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 97 | |
| 98 | header_win = subwin(stdscr, 1, maxx, 0, 0); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 99 | footer_win = subwin(stdscr, 1, maxx, maxy-1, 0); |
| 100 | |
| 101 | strcpy(footer_items[0], " Q (Quit) "); |
| 102 | strcpy(footer_items[1], " R (Refresh) "); |
| 103 | |
Amit Arora | 83ae6cb | 2010-12-02 12:22:19 +0530 | [diff] [blame] | 104 | if (selectedwindow == CLOCK) |
| 105 | strcpy(footer_items[2], " Other Keys: 'Left', 'Right', 'Up', 'Down', 'enter', " |
Amit Kucheria | a0adae4 | 2011-01-12 10:54:23 -0600 | [diff] [blame] | 106 | " '/', 'Esc' "); |
Amit Arora | 83ae6cb | 2010-12-02 12:22:19 +0530 | [diff] [blame] | 107 | else |
| 108 | strcpy(footer_items[2], " Other Keys: 'Left', 'Right' "); |
| 109 | |
| 110 | strcpy(footer_items[3], ""); |
| 111 | |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 112 | werase(stdscr); |
| 113 | refresh(); |
| 114 | |
| 115 | } |
| 116 | |
Daniel Lezcano | 558a6d5 | 2011-03-23 14:37:41 +0100 | [diff] [blame] | 117 | void create_selectedwindow(int selectedwindow) |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 118 | { |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 119 | WINDOW *win; |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 120 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 121 | killall_windows(0); |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 122 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 123 | getmaxyx(stdscr, maxy, maxx); |
Amit Arora | 24ed7d1 | 2010-09-14 12:12:58 +0530 | [diff] [blame] | 124 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 125 | win = subwin(stdscr, maxy - 2, maxx, 1, 0); |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 126 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 127 | switch (selectedwindow) { |
| 128 | case REGULATOR: regulator_win = win; |
Amit Kucheria | a0adae4 | 2011-01-12 10:54:23 -0600 | [diff] [blame] | 129 | break; |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 130 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 131 | case CLOCK: clock_win = win; |
Amit Kucheria | a0adae4 | 2011-01-12 10:54:23 -0600 | [diff] [blame] | 132 | break; |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 133 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 134 | case SENSOR: sensor_win = win; |
Amit Kucheria | a0adae4 | 2011-01-12 10:54:23 -0600 | [diff] [blame] | 135 | break; |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 136 | } |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 137 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 138 | selected_win = win; |
| 139 | |
| 140 | refresh(); |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 141 | } |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 142 | |
Daniel Lezcano | 558a6d5 | 2011-03-23 14:37:41 +0100 | [diff] [blame] | 143 | void show_header(int selectedwindow) |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 144 | { |
| 145 | int i, j = 0; |
Amit Kucheria | 0a4d019 | 2011-01-12 04:54:37 +0530 | [diff] [blame] | 146 | int curr_pointer = 0; |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 147 | |
| 148 | wattrset(header_win, COLOR_PAIR(PT_COLOR_HEADER_BAR)); |
| 149 | wbkgd(header_win, COLOR_PAIR(PT_COLOR_HEADER_BAR)); |
| 150 | werase(header_win); |
| 151 | |
Amit Kucheria | 0a4d019 | 2011-01-12 04:54:37 +0530 | [diff] [blame] | 152 | print(header_win, curr_pointer, 0, "PowerDebug %s", VERSION); |
| 153 | curr_pointer += 20; |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 154 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 155 | for (i = 0; i < TOTAL_FEATURE_WINS; i++) { |
| 156 | if (selectedwindow == i) |
| 157 | wattron(header_win, A_REVERSE); |
| 158 | else |
| 159 | wattroff(header_win, A_REVERSE); |
Amit Arora | c93e071 | 2010-10-07 13:51:53 +0530 | [diff] [blame] | 160 | |
Amit Kucheria | 0a4d019 | 2011-01-12 04:54:37 +0530 | [diff] [blame] | 161 | print(header_win, curr_pointer, 0, " %s ", win_names[i]); |
| 162 | curr_pointer += strlen(win_names[i]) + 2; |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 163 | } |
| 164 | wrefresh(header_win); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 165 | werase(footer_win); |
| 166 | |
Amit Kucheria | a0adae4 | 2011-01-12 10:54:23 -0600 | [diff] [blame] | 167 | for (i = 0; i < NUM_FOOTER_ITEMS; i++) { |
| 168 | if (strlen(footer_items[i]) == 0) |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 169 | continue; |
| 170 | wattron(footer_win, A_REVERSE); |
| 171 | print(footer_win, j, 0, "%s", footer_items[i]); |
| 172 | wattroff(footer_win, A_REVERSE); |
| 173 | j+= strlen(footer_items[i])+1; |
| 174 | } |
| 175 | wrefresh(footer_win); |
| 176 | } |
| 177 | |
| 178 | |
Daniel Lezcano | 833b63a | 2011-03-26 22:06:00 +0100 | [diff] [blame] | 179 | void show_regulator_info(struct regulator_info *reg_info, int nr_reg, int verbose) |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 180 | { |
Amit Arora | c93e071 | 2010-10-07 13:51:53 +0530 | [diff] [blame] | 181 | int i, count = 1; |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 182 | |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 183 | (void)verbose; |
Amit Arora | bf50db9 | 2010-10-07 14:09:05 +0530 | [diff] [blame] | 184 | |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 185 | werase(regulator_win); |
| 186 | wattron(regulator_win, A_BOLD); |
Amit Arora | c93e071 | 2010-10-07 13:51:53 +0530 | [diff] [blame] | 187 | print(regulator_win, 0, 0, "Name"); |
| 188 | print(regulator_win, 12, 0, "Status"); |
| 189 | print(regulator_win, 24, 0, "State"); |
| 190 | print(regulator_win, 36, 0, "Type"); |
| 191 | print(regulator_win, 48, 0, "Users"); |
| 192 | print(regulator_win, 60, 0, "Microvolts"); |
| 193 | print(regulator_win, 72, 0, "Min u-volts"); |
| 194 | print(regulator_win, 84, 0, "Max u-volts"); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 195 | wattroff(regulator_win, A_BOLD); |
| 196 | |
Daniel Lezcano | 833b63a | 2011-03-26 22:06:00 +0100 | [diff] [blame] | 197 | for (i = 0; i < nr_reg; i++) { |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 198 | int col = 0; |
| 199 | |
Amit Kucheria | a0adae4 | 2011-01-12 10:54:23 -0600 | [diff] [blame] | 200 | if ((i + 2) > (maxy-2)) |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 201 | break; |
| 202 | |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 203 | if (reg_info[i].num_users > 0) |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 204 | wattron(regulator_win, WA_BOLD); |
| 205 | else |
| 206 | wattroff(regulator_win, WA_BOLD); |
| 207 | |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 208 | print(regulator_win, col, count, "%s", |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 209 | reg_info[i].name); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 210 | col += 12; |
| 211 | print(regulator_win, col, count, "%s", |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 212 | reg_info[i].status); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 213 | col += 12; |
| 214 | print(regulator_win, col, count, "%s", |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 215 | reg_info[i].state); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 216 | col += 12; |
| 217 | print(regulator_win, col, count, "%s", |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 218 | reg_info[i].type); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 219 | col += 12; |
| 220 | print(regulator_win, col, count, "%d", |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 221 | reg_info[i].num_users); |
Amit Arora | 6a943ec | 2010-10-07 11:49:25 +0530 | [diff] [blame] | 222 | col += 12; |
| 223 | print(regulator_win, col, count, "%d", |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 224 | reg_info[i].microvolts); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 225 | col += 12; |
| 226 | print(regulator_win, col, count, "%d", |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 227 | reg_info[i].min_microvolts); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 228 | col += 12; |
| 229 | print(regulator_win, col, count, "%d", |
Daniel Lezcano | 3bd64f0 | 2011-03-26 22:05:56 +0100 | [diff] [blame] | 230 | reg_info[i].max_microvolts); |
Amit Arora | 47fd918 | 2010-08-24 13:26:06 +0530 | [diff] [blame] | 231 | |
| 232 | count++; |
| 233 | } |
| 234 | wrefresh(regulator_win); |
| 235 | } |
| 236 | |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 237 | |
Amit Arora | ac4e865 | 2010-11-09 11:16:53 +0530 | [diff] [blame] | 238 | void print_clock_header(void) |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 239 | { |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 240 | werase(clock_win); |
| 241 | wattron(clock_win, A_BOLD); |
Amit Arora | ac4e865 | 2010-11-09 11:16:53 +0530 | [diff] [blame] | 242 | print(clock_win, 0, 0, "Name"); |
Amit Arora | 031263a | 2010-11-09 11:12:41 +0530 | [diff] [blame] | 243 | print(clock_win, 54, 0, "Flags"); |
| 244 | print(clock_win, 64, 0, "Rate"); |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 245 | print(clock_win, 72, 0, "Usecount"); |
Amit Arora | 04f9774 | 2010-11-16 11:28:57 +0530 | [diff] [blame] | 246 | print(clock_win, 84, 0, "Children"); |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 247 | wattroff(clock_win, A_BOLD); |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 248 | wrefresh(clock_win); |
| 249 | } |
| 250 | |
| 251 | void print_sensor_header(void) |
| 252 | { |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 253 | werase(sensor_win); |
| 254 | wattron(sensor_win, A_BOLD); |
| 255 | print(sensor_win, 0, 0, "Name"); |
| 256 | print(sensor_win, 36, 0, "Temperature"); |
| 257 | wattroff(sensor_win, A_BOLD); |
| 258 | wattron(sensor_win, A_BLINK); |
| 259 | print(sensor_win, 0, 1, "Currently Sensor information available" |
Amit Kucheria | a0adae4 | 2011-01-12 10:54:23 -0600 | [diff] [blame] | 260 | " only in Dump mode!"); |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 261 | wattroff(sensor_win, A_BLINK); |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 262 | wrefresh(sensor_win); |
| 263 | } |
| 264 | |
Amit Arora | ac4e865 | 2010-11-09 11:16:53 +0530 | [diff] [blame] | 265 | void print_one_clock(int line, char *str, int bold, int highlight) |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 266 | { |
Amit Arora | 031263a | 2010-11-09 11:12:41 +0530 | [diff] [blame] | 267 | if (bold) |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 268 | wattron(clock_win, WA_BOLD); |
Amit Arora | ac4e865 | 2010-11-09 11:16:53 +0530 | [diff] [blame] | 269 | if (highlight) |
| 270 | wattron(clock_win, WA_STANDOUT); |
| 271 | |
Amit Arora | 031263a | 2010-11-09 11:12:41 +0530 | [diff] [blame] | 272 | print(clock_win, 0, line + 1, "%s", str); |
| 273 | if (bold) |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 274 | wattroff(clock_win, WA_BOLD); |
Amit Arora | ac4e865 | 2010-11-09 11:16:53 +0530 | [diff] [blame] | 275 | if (highlight) |
| 276 | wattroff(clock_win, WA_STANDOUT); |
Amit Arora | 6e774cd | 2010-10-28 11:31:24 +0530 | [diff] [blame] | 277 | wrefresh(clock_win); |
Amit Arora | 728e0c9 | 2010-09-14 12:06:09 +0530 | [diff] [blame] | 278 | } |