summaryrefslogtreecommitdiff
path: root/riscos
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2014-01-22 23:19:57 +0000
committerVincent Sanders <vince@kyllikki.org>2014-01-23 00:00:18 +0000
commit047569339406f2be1637ae4cee5dd0c9a9c2328f (patch)
tree3d3909b4bc3d27cd7a9e146d32539ce752b33310 /riscos
parent4684e9665d2ddff50f4a8e9a16d73224d2617180 (diff)
downloadnetsurf-047569339406f2be1637ae4cee5dd0c9a9c2328f.tar.gz
netsurf-047569339406f2be1637ae4cee5dd0c9a9c2328f.tar.bz2
create table for fetcher operations and move all operations into it
Diffstat (limited to 'riscos')
-rw-r--r--riscos/gui.c14
-rw-r--r--riscos/gui.h2
2 files changed, 13 insertions, 3 deletions
diff --git a/riscos/gui.c b/riscos/gui.c
index 6160956c7..8495dd6aa 100644
--- a/riscos/gui.c
+++ b/riscos/gui.c
@@ -2353,15 +2353,22 @@ static struct gui_clipboard_table riscos_clipboard_table = {
.set = gui_set_clipboard,
};
+static struct gui_fetch_table riscos_fetch_table = {
+ .filename_from_path = filename_from_path,
+ .path_add_part = path_add_part,
+ .filetype = fetch_filetype,
+
+ .get_resource_url = gui_get_resource_url,
+ .mimetype = fetch_mimetype,
+};
+
static struct gui_browser_table riscos_browser_table = {
.poll = gui_poll,
+
.quit = gui_quit,
- .get_resource_url = gui_get_resource_url,
.launch_url = gui_launch_url,
.create_form_select_menu = gui_create_form_select_menu,
.cert_verify = gui_cert_verify,
- .filename_from_path = filename_from_path,
- .path_add_part = path_add_part,
.login = gui_401login_open,
};
@@ -2381,6 +2388,7 @@ int main(int argc, char** argv)
.window = riscos_window_table,
.clipboard = &riscos_clipboard_table,
.download = riscos_download_table,
+ .fetch = &riscos_fetch_table,
};
/* Consult NetSurf$Logging environment variable to decide if logging
diff --git a/riscos/gui.h b/riscos/gui.h
index c3dce1cb8..3eeb56273 100644
--- a/riscos/gui.h
+++ b/riscos/gui.h
@@ -167,6 +167,8 @@ void ro_gui_history_open(struct browser_window *bw, struct history *history,
bool pointer);
/* in filetype.c */
+const char *fetch_filetype(const char *unix_path);
+char *fetch_mimetype(const char *ro_path);
int ro_content_filetype(struct hlcache_handle *c);
int ro_content_native_type(struct hlcache_handle *c);
int ro_content_filetype_from_mime_type(lwc_string *mime_type);