diff --git a/frontends/riscos/filetype.c b/frontends/riscos/filetype.c index 73651cd63..d75214191 100644 --- a/frontends/riscos/filetype.c +++ b/frontends/riscos/filetype.c @@ -39,6 +39,7 @@ static const struct type_entry type_map[] = { {0x188, "application/x-shockwave-flash"}, {0x695, "image/gif"}, {0x69c, "image/x-ms-bmp"}, + {0xa66, "image/webp"}, {0xaad, "image/svg+xml"}, {0xaff, "image/x-drawfile"}, {0xb60, "image/png"}, @@ -269,6 +270,7 @@ int ro_content_native_type(struct hlcache_handle *c) case FILETYPE_BMP: /* bmp */ case FILETYPE_ICO: /* ico */ case FILETYPE_PNG: /* png */ + case FILETYPE_WEBP: /* webp */ case 0xff9: /* sprite */ return osfile_TYPE_SPRITE; case FILETYPE_SVG: /* svg */ diff --git a/frontends/riscos/filetype.h b/frontends/riscos/filetype.h index 4c45e7bd0..b9fca4d49 100644 --- a/frontends/riscos/filetype.h +++ b/frontends/riscos/filetype.h @@ -67,6 +67,9 @@ #ifndef FILETYPE_SVG #define FILETYPE_SVG 0xaad #endif +#ifndef FILETYPE_WEBP +#define FILETYPE_WEBP 0xa66 +#endif /** * Determine the MIME type of a local file. diff --git a/frontends/riscos/gui.c b/frontends/riscos/gui.c index b0eb23256..cc12eaccb 100644 --- a/frontends/riscos/gui.c +++ b/frontends/riscos/gui.c @@ -827,6 +827,7 @@ static void ro_msg_dataload(wimp_message *message) case osfile_TYPE_TEXT: case FILETYPE_ARTWORKS: case FILETYPE_SVG: + case FILETYPE_WEBP: /* display the actual file */ error = netsurf_path_to_nsurl(message->data.data_xfer.file_name, &url); break; @@ -929,7 +930,8 @@ static void ro_msg_datasave(wimp_message *message) case osfile_TYPE_SPRITE: case osfile_TYPE_TEXT: case FILETYPE_ARTWORKS: - case FILETYPE_SVG: { + case FILETYPE_SVG: + case FILETYPE_WEBP: { os_error *error; dataxfer->your_ref = dataxfer->my_ref;