viking

webkit based web browser for Enlightenment
Log | Files | Refs | LICENSE

commit b8ebed73f699cddf7dc6d41fda384737f1a5b10f
parent 139d4dd79250922081ffa84bf08262565246fa23
Author: Kyle Milz <kmilz@ucalgary.ca>
Date:   Tue, 25 Sep 2012 13:54:43 -0600

remove some globals

Diffstat:
Msrc/main.c | 16+++++-----------
1 file changed, 5 insertions(+), 11 deletions(-)

diff --git a/src/main.c b/src/main.c @@ -69,13 +69,7 @@ enable_proxy(Buffer_Data *bd) } } -static const char statusfont[] = "monospace bold 8"; /* font for status bar */ -static const int progressbartick = 20; -static const char progressborderleft = '['; -static const char progressbartickchar = '='; -static const char progressbarcurrent = '>'; -static const char progressbarspacer = ' '; -static const char progressborderright = ']'; +static const int progressbartick = 10; static void ascii_bar(int total, int state, char *string) @@ -83,10 +77,10 @@ ascii_bar(int total, int state, char *string) int i; for (i = 0; i < state; i++) - string[i] = progressbartickchar; - string[i++] = progressbarcurrent; + string[i] = '='; + string[i++] = '>'; for (; i < total; i++) - string[i] = progressbarspacer; + string[i] = ' '; string[i] = '\0'; } @@ -150,7 +144,7 @@ update_state(void *data) if (progress >= 0) { ascii_bar(progressbartick, progress * progressbartick / 100, progressbar); char *load_progress = strdup_printf(" %c%s%c", - progressborderleft, progressbar, progressborderright); + '[', progressbar, ']'); strcat(status, load_progress); free(load_progress); }