NetSurf
download.h
Go to the documentation of this file.
1/*
2 * Copyright 2014 Vincent Sanders <vince@netsurf-browser.org>
3 *
4 * This file is part of NetSurf, http://www.netsurf-browser.org/
5 *
6 * NetSurf is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; version 2 of the License.
9 *
10 * NetSurf is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19/**
20 * \file
21 *
22 * Interface to platform-specific download operations.
23 */
24
25#ifndef _NETSURF_DOWNLOAD_H_
26#define _NETSURF_DOWNLOAD_H_
27
28struct gui_window;
29struct download_context;
30
31/**
32 * function table for download windows.
33 */
35 struct gui_download_window *(*create)(struct download_context *ctx, struct gui_window *parent);
36
37 nserror (*data)(struct gui_download_window *dw, const char *data, unsigned int size);
38
39 void (*error)(struct gui_download_window *dw, const char *error_msg);
40
41 void (*done)(struct gui_download_window *dw);
42};
43
44#endif
wimp_w parent
Definition: dialog.c:88
nserror
Enumeration of error codes.
Definition: errors.h:29
A context for a download.
Definition: download.c:40
function table for download windows.
Definition: download.h:34
nserror(* data)(struct gui_download_window *dw, const char *data, unsigned int size)
Definition: download.h:37
void(* done)(struct gui_download_window *dw)
Definition: download.h:41
void(* error)(struct gui_download_window *dw, const char *error_msg)
Definition: download.h:39
context for each download.
Definition: download.c:91
first entry in window list
Definition: gui.c:297