From 7dcc725ae2e9351d4b8fb5350b0157cd4699d9fb Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Sun, 12 Jun 2016 00:13:04 +0100 Subject: [PATCH] reduce cocoa frontend use of content API --- frontends/cocoa/BookmarksController.m | 2 +- frontends/cocoa/BrowserView.m | 3 ++- frontends/cocoa/BrowserViewController.m | 6 +++--- frontends/cocoa/NetsurfApp.m | 7 +++---- frontends/cocoa/PreferencesWindowController.m | 3 +-- frontends/cocoa/bitmap.m | 1 - frontends/cocoa/gui.m | 8 +++----- 7 files changed, 13 insertions(+), 17 deletions(-) diff --git a/frontends/cocoa/BookmarksController.m b/frontends/cocoa/BookmarksController.m index e11cb3f84..2d574f39b 100644 --- a/frontends/cocoa/BookmarksController.m +++ b/frontends/cocoa/BookmarksController.m @@ -18,10 +18,10 @@ #import "utils/messages.h" #import "utils/utils.h" +#import "utils/nsurl.h" #import "netsurf/browser_window.h" #import "desktop/hotlist.h" #import "desktop/tree.h" -#import "content/hlcache.h" #import "cocoa/BookmarksController.h" #import "cocoa/Tree.h" diff --git a/frontends/cocoa/BrowserView.m b/frontends/cocoa/BrowserView.m index db1c2492d..d2f3f51b4 100644 --- a/frontends/cocoa/BrowserView.m +++ b/frontends/cocoa/BrowserView.m @@ -18,10 +18,11 @@ #import "utils/nsoption.h" #import "utils/messages.h" +#import "utils/nsurl.h" #import "netsurf/browser_window.h" #import "netsurf/plotters.h" +#import "netsurf/content.h" #import "desktop/textinput.h" -#import "content/hlcache.h" #import "cocoa/gui.h" #import "cocoa/BrowserView.h" diff --git a/frontends/cocoa/BrowserViewController.m b/frontends/cocoa/BrowserViewController.m index 354015194..777f4bc5d 100644 --- a/frontends/cocoa/BrowserViewController.m +++ b/frontends/cocoa/BrowserViewController.m @@ -21,11 +21,11 @@ #import "utils/filename.h" #import "utils/file.h" #import "utils/messages.h" -#import "utils/url.h" -#import "desktop/browser_history.h" +#import "utils/nsurl.h" +#import "netsurf/content.h" #import "netsurf/browser_window.h" +#import "desktop/browser_history.h" #import "desktop/textinput.h" -#import "content/hlcache.h" #import "cocoa/gui.h" #import "cocoa/BrowserViewController.h" diff --git a/frontends/cocoa/NetsurfApp.m b/frontends/cocoa/NetsurfApp.m index a8619e0ac..5becdf92b 100644 --- a/frontends/cocoa/NetsurfApp.m +++ b/frontends/cocoa/NetsurfApp.m @@ -31,15 +31,14 @@ #import "utils/log.h" #import "utils/messages.h" #import "utils/utils.h" -#import "content/urldb.h" #import "utils/nsoption.h" #import "netsurf/plotters.h" +#import "netsurf/mouse.h" +#import "netsurf/netsurf.h" +#import "content/urldb.h" #import "desktop/save_complete.h" #import "desktop/textinput.h" #import "desktop/tree.h" -#import "render/html.h" -#import "netsurf/mouse.h" -#import "netsurf/netsurf.h" #ifndef NETSURF_HOMEPAGE #define NETSURF_HOMEPAGE "http://www.netsurf-browser.org/welcome/" diff --git a/frontends/cocoa/PreferencesWindowController.m b/frontends/cocoa/PreferencesWindowController.m index 752218626..590a96818 100644 --- a/frontends/cocoa/PreferencesWindowController.m +++ b/frontends/cocoa/PreferencesWindowController.m @@ -17,9 +17,8 @@ */ #import "utils/nsoption.h" +#import "utils/nsurl.h" #import "netsurf/browser_window.h" -#import "content/content.h" -#import "content/hlcache.h" #import "cocoa/PreferencesWindowController.h" #import "cocoa/NetsurfApp.h" diff --git a/frontends/cocoa/bitmap.m b/frontends/cocoa/bitmap.m index 4a87e233c..1ab8c3e2f 100644 --- a/frontends/cocoa/bitmap.m +++ b/frontends/cocoa/bitmap.m @@ -27,7 +27,6 @@ #import "netsurf/plotters.h" #import "netsurf/bitmap.h" #import "netsurf/content.h" -#import "content/urldb.h" #import "cocoa/plotter.h" #import "cocoa/bitmap.h" diff --git a/frontends/cocoa/gui.m b/frontends/cocoa/gui.m index 310e196a3..5702bb3d9 100644 --- a/frontends/cocoa/gui.m +++ b/frontends/cocoa/gui.m @@ -21,15 +21,13 @@ #import "utils/nsoption.h" #import "utils/utils.h" #import "utils/log.h" +#import "utils/nsurl.h" #import "netsurf/mouse.h" #import "netsurf/window.h" #import "netsurf/misc.h" #import "netsurf/browser_window.h" +#import "netsurf/content.h" #import "desktop/textinput.h" -#import "content/handlers/image/ico.h" -#import "content/fetchers/resource.h" -#import "content/hlcache.h" -#import "content/content.h" #import "cocoa/gui.h" #import "cocoa/plotter.h" @@ -227,7 +225,7 @@ static void gui_window_stop_throbber(struct gui_window *g) [(BrowserViewController *)g updateBackForward]; } -static void gui_window_set_icon(struct gui_window *g, hlcache_handle *icon) +static void gui_window_set_icon(struct gui_window *g, struct hlcache_handle *icon) { NSBitmapImageRep *bmp = NULL; NSImage *image = nil;