From a821e0e87480e8b812ab5975c1031d5ee5eb2587 Mon Sep 17 00:00:00 2001 From: corvid Date: Mon, 22 Dec 2008 08:45:53 -0300 Subject: Added some const quialifiers. --- src/IO/about.c | 2 +- src/form.cc | 2 +- src/menu.cc | 2 +- src/ui.cc | 3 ++- 4 files changed, 5 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/IO/about.c b/src/IO/about.c index 27b24f47..03d5057c 100644 --- a/src/IO/about.c +++ b/src/IO/about.c @@ -14,7 +14,7 @@ /* * HTML text for startup screen */ -const char *AboutSplash= +const char *const AboutSplash= "\n" "\n" "\n" diff --git a/src/form.cc b/src/form.cc index 219b3b5d..76f2c32b 100644 --- a/src/form.cc +++ b/src/form.cc @@ -342,7 +342,7 @@ void Html_tag_open_form(DilloHtml *html, const char *tag, int tagsize) void Html_tag_close_form(DilloHtml *html, int TagIdx) { - static const char *SubmitTag = + static const char *const SubmitTag = ""; DilloHtmlForm *form; // int i; diff --git a/src/menu.cc b/src/menu.cc index 9b75c422..54babc0b 100644 --- a/src/menu.cc +++ b/src/menu.cc @@ -38,7 +38,7 @@ static DilloUrl *popup_url = NULL; // Weak reference to the popup's bw static BrowserWindow *popup_bw = NULL; // Where to place the filemenu popup -int popup_x, popup_y; +static int popup_x, popup_y; // History popup direction (-1 = back, 1 = forward). static int history_direction = -1; // History popup, list of URL-indexes. diff --git a/src/ui.cc b/src/ui.cc index b47e11cf..9af1b2a4 100644 --- a/src/ui.cc +++ b/src/ui.cc @@ -993,7 +993,8 @@ void UI::panel_cb_i() */ void UI::color_change_cb_i() { - static int ncolor = 0, cols[] = {7,17,26,51,140,156,205,206,215,-1}; + const int cols[] = {7,17,26,51,140,156,205,206,215,-1}; + static int ncolor = 0; ncolor = (cols[ncolor+1] < 0) ? 0 : ncolor + 1; CuteColor = cols[ncolor]; -- cgit v1.2.3