diff options
author | Michael Drake <tlsa@netsurf-browser.org> | 2014-10-16 09:22:05 +0100 |
---|---|---|
committer | Michael Drake <tlsa@netsurf-browser.org> | 2014-10-16 09:22:05 +0100 |
commit | b4b97d90032e7c52f1888b1b32132e30c0bd4094 (patch) | |
tree | e4d73caf97f443343d229d4c7d639c5c0417f98c /riscos/gui/url_bar.c | |
parent | cb976f24c7dc2892d940945dc64866f4904349c4 (diff) | |
download | netsurf-b4b97d90032e7c52f1888b1b32132e30c0bd4094.tar.gz netsurf-b4b97d90032e7c52f1888b1b32132e30c0bd4094.tar.bz2 |
Chage favicon set APIs to take gui_window rather than hlcache_handle.
Let the front end pass its own types around, rather than core ones.
This removes one "bw->current_content" from window.c.
Now the current content is only accessed where its needed, in the
favicon handler, and it is accessed via the appropriate API.
Diffstat (limited to 'riscos/gui/url_bar.c')
-rw-r--r-- | riscos/gui/url_bar.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/riscos/gui/url_bar.c b/riscos/gui/url_bar.c index d89004856..76a63aa2d 100644 --- a/riscos/gui/url_bar.c +++ b/riscos/gui/url_bar.c @@ -1164,13 +1164,16 @@ bool ro_gui_url_bar_test_for_text_field_keypress(struct url_bar *url_bar, /* This is an exported interface documented in url_bar.h */ bool ro_gui_url_bar_set_site_favicon(struct url_bar *url_bar, - struct hlcache_handle *h) + struct gui_window *g) { + struct hlcache_handle *h content_type type = CONTENT_NONE; - if (url_bar == NULL) + if (url_bar == NULL || g == NULL) return false; + h = browser_window_get_content(g->bw); + if (h != NULL) type = content_get_type(h); |