From 4e7dcde2b056c16a96dde6adcadb29a65ca72fde Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Fri, 24 Apr 2015 10:54:32 +0100 Subject: Update monkey to use bitmap render API --- monkey/Makefile.target | 5 ++--- monkey/bitmap.c | 9 +++++++++ monkey/thumbnail.c | 30 ------------------------------ 3 files changed, 11 insertions(+), 33 deletions(-) delete mode 100644 monkey/thumbnail.c diff --git a/monkey/Makefile.target b/monkey/Makefile.target index cb7bf1717..4f73ad068 100644 --- a/monkey/Makefile.target +++ b/monkey/Makefile.target @@ -57,9 +57,8 @@ endif # ---------------------------------------------------------------------------- # S_MONKEY are sources purely for the MONKEY build -S_MONKEY := main.c utils.c filetype.c schedule.c \ - bitmap.c plot.c browser.c download.c thumbnail.c \ - 401login.c cert.c font.c poll.c dispatch.c fetch.c +S_MONKEY := main.c utils.c filetype.c schedule.c bitmap.c plot.c browser.c \ + download.c 401login.c cert.c font.c poll.c dispatch.c fetch.c S_MONKEY := $(addprefix monkey/,$(S_MONKEY)) diff --git a/monkey/bitmap.c b/monkey/bitmap.c index 16c98b594..5605073ba 100644 --- a/monkey/bitmap.c +++ b/monkey/bitmap.c @@ -20,6 +20,7 @@ #include #include +#include "utils/errors.h" #include "image/bitmap.h" #include "monkey/bitmap.h" @@ -123,6 +124,13 @@ static int bitmap_get_height(void *bitmap) return bmap->height; } +static nserror bitmap_render(struct bitmap *bitmap, + struct hlcache_handle *content) +{ + fprintf(stdout, "GENERIC BITMAP RENDER\n"); + return NSERROR_OK; +} + static struct gui_bitmap_table bitmap_table = { .create = bitmap_create, .destroy = bitmap_destroy, @@ -136,6 +144,7 @@ static struct gui_bitmap_table bitmap_table = { .get_bpp = bitmap_get_bpp, .save = bitmap_save, .modified = bitmap_modified, + .render = bitmap_render, }; struct gui_bitmap_table *monkey_bitmap_table = &bitmap_table; diff --git a/monkey/thumbnail.c b/monkey/thumbnail.c deleted file mode 100644 index b49944b12..000000000 --- a/monkey/thumbnail.c +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright 2011 Daniel Silverstone - * - * This file is part of NetSurf, http://www.netsurf-browser.org/ - * - * NetSurf is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; version 2 of the License. - * - * NetSurf is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -#include - -#include "desktop/thumbnail.h" -#include "content/hlcache.h" - -#include "monkey/browser.h" - -bool thumbnail_create(hlcache_handle *content, struct bitmap *bitmap) -{ - fprintf(stdout, "GENERIC THUMBNAIL\n"); - return false; -} -- cgit v1.2.3