Author: jmb
Date: Sun Feb 28 10:04:37 2010
New Revision: 10087
URL:
http://source.netsurf-browser.org?rev=10087&view=rev
Log:
s/struct content/hlcache_handle/ in imagemap_get API
Modified:
branches/jmb/new-cache/render/imagemap.c
branches/jmb/new-cache/render/imagemap.h
Modified: branches/jmb/new-cache/render/imagemap.c
URL:
http://source.netsurf-browser.org/branches/jmb/new-cache/render/imagemap....
==============================================================================
--- branches/jmb/new-cache/render/imagemap.c (original)
+++ branches/jmb/new-cache/render/imagemap.c Sun Feb 28 10:04:37 2010
@@ -25,6 +25,7 @@
#include <string.h>
#include <strings.h>
#include "content/content_protected.h"
+#include "content/hlcache.h"
#include "render/box.h"
#include "render/imagemap.h"
#include "utils/log.h"
@@ -626,20 +627,21 @@
/**
* Retrieve url associated with imagemap entry
*
- * \param c The containing content
- * \param key The map name to search for
- * \param x The left edge of the containing box
- * \param y The top edge of the containing box
- * \param click_x The horizontal location of the click
- * \param click_y The vertical location of the click
- * \param target Pointer to location to receive target pointer (if any)
+ * \param h The containing content
+ * \param key The map name to search for
+ * \param x The left edge of the containing box
+ * \param y The top edge of the containing box
+ * \param click_x The horizontal location of the click
+ * \param click_y The vertical location of the click
+ * \param target Pointer to location to receive target pointer (if any)
* \return The url associated with this area, or NULL if not found
*/
-const char *imagemap_get(struct content *c, const char *key,
+const char *imagemap_get(hlcache_handle *h, const char *key,
unsigned long x, unsigned long y,
unsigned long click_x, unsigned long click_y,
const char **target)
{
+ struct content *c = hlcache_handle_get_content(h);
unsigned int slot = 0;
struct imagemap *map;
struct mapentry *entry;
Modified: branches/jmb/new-cache/render/imagemap.h
URL:
http://source.netsurf-browser.org/branches/jmb/new-cache/render/imagemap....
==============================================================================
--- branches/jmb/new-cache/render/imagemap.h (original)
+++ branches/jmb/new-cache/render/imagemap.h Sun Feb 28 10:04:37 2010
@@ -22,11 +22,13 @@
#include <libxml/HTMLtree.h>
struct content;
+struct hlcache_handle;
void imagemap_destroy(struct content *c);
void imagemap_dump(struct content *c);
bool imagemap_extract(xmlNode *node, struct content *c);
-const char *imagemap_get(struct content *c, const char *key,
+
+const char *imagemap_get(struct hlcache_handle *h, const char *key,
unsigned long x, unsigned long y,
unsigned long click_x, unsigned long click_y,
const char **target);