diff options
author | Vincent Sanders <vince@netsurf-browser.org> | 2010-02-11 00:10:58 +0000 |
---|---|---|
committer | Vincent Sanders <vince@netsurf-browser.org> | 2010-02-11 00:10:58 +0000 |
commit | c1e7429d58093a640f66090e679203c2c084d863 (patch) | |
tree | 51a0b9b6f132bb0e7a004fd3304a42f681dc3b99 | |
parent | 1537981da5415302438489617422b0e3f9b4c6e9 (diff) | |
download | netsurf-c1e7429d58093a640f66090e679203c2c084d863.tar.gz netsurf-c1e7429d58093a640f66090e679203c2c084d863.tar.bz2 |
remove RISC OS status bar text caching
svn path=/trunk/netsurf/; revision=9966
-rw-r--r-- | desktop/browser.c | 2 | ||||
-rw-r--r-- | riscos/gui/status_bar.c | 25 |
2 files changed, 3 insertions, 24 deletions
diff --git a/desktop/browser.c b/desktop/browser.c index 2a3d8d7ea..4986176d7 100644 --- a/desktop/browser.c +++ b/desktop/browser.c @@ -936,7 +936,7 @@ void browser_window_set_status(struct browser_window *bw, const char *text) } bw->status_miss++; - gui_window_set_status(bw->window, text); + gui_window_set_status(bw->window, bw->status_text); } diff --git a/riscos/gui/status_bar.c b/riscos/gui/status_bar.c index 087fd861b..75208ff64 100644 --- a/riscos/gui/status_bar.c +++ b/riscos/gui/status_bar.c @@ -314,31 +314,10 @@ void ro_gui_status_bar_set_text(struct status_bar *sb, const char *text) { assert(sb); - /* check for no change */ - if (sb->text) { - /* strings match */ - if (!strcmp(text, sb->text)) - return; - } else { - /* still no string */ - if (!text) - return; - } - - /* release the old text */ - if (sb->text) - free(sb->text); - - /* copy new text if required. we don't abort on the string duplication - * failing as it would just cause the visible display to be out of - * sync with the (failed) text */ - if (text) - sb->text = strdup(text); - else - sb->text = NULL; + sb->text = text; /* redraw the window */ - if (sb->visible) + if ((sb->visible) && (text != NULL)) xwimp_force_redraw(sb->w, 0, 0, sb->width - WIDGET_WIDTH, 65536); } |