From 3afd9c97310d58c0c6588d18887244328590731e Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Tue, 7 May 2013 14:41:40 +0100 Subject: Remove search context from browser window, simplify search interface for front ends. Added content interface for search. Removed bw->cur_search search context. Desktop layer now does nothing except pass search requests from front end onto the bw's current_content via the content interface. Search API reduced to a pair of functions at each level: {desktop|content|html|textplain}_search and {desktop|content|html|textplain}_search_clear Updated front ends to use simplified search API. Only tested GTK and RO builds. These confine the search stuff to render/. However search still uses struct selection. The handling for which is still spread over desktop/ and render/. Also the render/search code itself still fiddles inside html and textplain privates. --- content/content_protected.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'content/content_protected.h') diff --git a/content/content_protected.h b/content/content_protected.h index 8efe763aa..57ce35775 100644 --- a/content/content_protected.h +++ b/content/content_protected.h @@ -73,6 +73,11 @@ struct content_handler { int scrx, int scry); bool (*drop_file_at_point)(struct content *c, int x, int y, char *file); + void (*search)(struct content *c, + struct gui_search_callbacks *gui_callbacks, + void *gui_data, search_flags_t flags, + const char *string); + void (*search_clear)(struct content *c); void (*debug_dump)(struct content *c, FILE *f); nserror (*clone)(const struct content *old, struct content **newc); bool (*matches_quirks)(const struct content *c, bool quirks); -- cgit v1.2.3