summaryrefslogtreecommitdiff
path: root/desktop/browser.c
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2010-04-04 12:41:19 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2010-04-04 12:41:19 +0000
commit79ce683b4e6d34fe327b00f1e427e476016cfab0 (patch)
tree2ed3ba800e8f570000f97588ce668eb47168565a /desktop/browser.c
parent3daffe3d6b07be7bbeedbcb2586f11edd872cbd6 (diff)
downloadnetsurf-79ce683b4e6d34fe327b00f1e427e476016cfab0.tar.gz
netsurf-79ce683b4e6d34fe327b00f1e427e476016cfab0.tar.bz2
Most of a stop implementation.
Remaining work: 1) Clone content_html_data 2) Cloning content_css_data requires the charset of the old content 3) Calling hlcache_handle_abort() before a content has been created must clean up the retrieval context. svn path=/trunk/netsurf/; revision=10236
Diffstat (limited to 'desktop/browser.c')
-rw-r--r--desktop/browser.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/desktop/browser.c b/desktop/browser.c
index 57a4f59b2..70d6b8cf4 100644
--- a/desktop/browser.c
+++ b/desktop/browser.c
@@ -811,16 +811,18 @@ void browser_window_stop(struct browser_window *bw)
int children, index;
if (bw->loading_content != NULL) {
+ hlcache_handle_abort(bw->loading_content);
hlcache_handle_release(bw->loading_content);
bw->loading_content = NULL;
}
if (bw->current_content != NULL && content_get_status(
bw->current_content) != CONTENT_STATUS_DONE) {
+ nserror error;
assert(content_get_status(bw->current_content) ==
CONTENT_STATUS_READY);
- content_stop(bw->current_content,
- browser_window_callback, bw);
+ error = hlcache_handle_abort(bw->current_content);
+ assert(error == NSERROR_OK);
}
schedule_remove(browser_window_refresh, bw);