diff --git a/amiga/arexx.c b/amiga/arexx.c
index 4130dbb6d..7a367e893 100644
--- a/amiga/arexx.c
+++ b/amiga/arexx.c
@@ -16,17 +16,6 @@
* along with this program. If not, see .
*/
-#include "amiga/os3support.h"
-
-#include "amiga/arexx.h"
-#include "amiga/download.h"
-#include "amiga/gui.h"
-#include "amiga/hotlist.h"
-#include "amiga/theme.h"
-#include "utils/nsoption.h"
-
-#include "desktop/browser_private.h"
-#include "desktop/version.h"
#include
#include
@@ -38,11 +27,20 @@
#include
#include
+#include "utils/nsoption.h"
+#include "desktop/browser_private.h"
+#include "desktop/gui_window.h"
+#include "desktop/version.h"
+
+#include "amiga/os3support.h"
+#include "amiga/arexx.h"
+#include "amiga/download.h"
+#include "amiga/gui.h"
+#include "amiga/hotlist.h"
+#include "amiga/theme.h"
+
extern const char * const verarexx;
-extern const char * const netsurf_version;
extern const char * const wt_revid;
-extern const int netsurf_version_major;
-extern const int netsurf_version_minor;
enum
{
@@ -106,13 +104,13 @@ STATIC struct ARexxCmd Commands[] =
BOOL ami_arexx_init(void)
{
- if(arexx_obj = ARexxObject,
+ if((arexx_obj = ARexxObject,
AREXX_HostName,"NETSURF",
AREXX_Commands,Commands,
AREXX_NoSlot,TRUE,
AREXX_ReplyHook,NULL,
AREXX_DefExtension,"nsrx",
- End)
+ End))
{
GetAttr(AREXX_SigMask, arexx_obj, &rxsig);
return true;
@@ -147,7 +145,7 @@ void ami_arexx_cleanup(void)
if(arexx_obj) DisposeObject(arexx_obj);
}
-struct browser_window *ami_find_tab_gwin(struct gui_window_2 *gwin, int tab)
+static struct browser_window *ami_find_tab_gwin(struct gui_window_2 *gwin, int tab)
{
int tabs = 0;
struct Node *ctab;
@@ -166,12 +164,12 @@ struct browser_window *ami_find_tab_gwin(struct gui_window_2 *gwin, int tab)
TNA_UserData, &bw,
TAG_DONE);
if(tabs == tab) return bw;
- } while(ctab=ntab);
+ } while((ctab=ntab));
return NULL;
}
-int ami_find_tab_bw(struct gui_window_2 *gwin, struct browser_window *bw)
+static int ami_find_tab_bw(struct gui_window_2 *gwin, struct browser_window *bw)
{
int tabs = 0;
struct Node *ctab;
@@ -190,12 +188,12 @@ int ami_find_tab_bw(struct gui_window_2 *gwin, struct browser_window *bw)
TNA_UserData, &tbw,
TAG_DONE);
if(tbw == bw) return tabs;
- } while(ctab=ntab);
+ } while((ctab=ntab));
return 0;
}
-struct browser_window *ami_find_tab(int window, int tab)
+static struct browser_window *ami_find_tab(int window, int tab)
{
struct nsObject *node, *nnode;
@@ -215,7 +213,7 @@ struct browser_window *ami_find_tab(int window, int tab)
if(windows == window)
return ami_find_tab_gwin(node->objstruct, tab);
}
- } while(node = nnode);
+ } while((node = nnode));
}
return NULL;
}
@@ -563,8 +561,8 @@ STATIC VOID rx_windows(struct ARexxCmd *cmd, struct RexxMsg *rxm __attribute__((
} while(node = nnode);
}
- if(cmd->ac_ArgList[0]) sprintf(result, "%ld", tabs);
- else sprintf(result, "%ld", windows);
+ if(cmd->ac_ArgList[0]) sprintf(result, "%d", tabs);
+ else sprintf(result, "%d", windows);
cmd->ac_Result = result;
}
@@ -606,8 +604,8 @@ STATIC VOID rx_active(struct ARexxCmd *cmd, struct RexxMsg *rxm __attribute__((u
tab = ami_find_tab_bw(gwin, bw);
}
- if(cmd->ac_ArgList[0]) sprintf(result, "%ld", tab);
- else sprintf(result, "%ld", window);
+ if(cmd->ac_ArgList[0]) sprintf(result, "%d", tab);
+ else sprintf(result, "%d", window);
cmd->ac_Result = result;
}
diff --git a/amiga/bitmap.c b/amiga/bitmap.c
index 271978b2e..bab6746c7 100644
--- a/amiga/bitmap.c
+++ b/amiga/bitmap.c
@@ -18,9 +18,6 @@
#include "amiga/os3support.h"
-#include "assert.h"
-#include "amiga/bitmap.h"
-#include "amiga/download.h"
#include
#include
#ifdef __amigaos4__
@@ -34,7 +31,15 @@
#include
#include
#include
+#include "assert.h"
+
#include "utils/messages.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/gui.h"
+#include "amiga/bitmap.h"
+#include "amiga/download.h"
/**
* Create a bitmap.
@@ -290,6 +295,7 @@ void ami_bitmap_argb_to_rgba(struct bitmap *bm)
}
#endif
+#if BITMAP_DUMP
void bitmap_dump(struct bitmap *bitmap)
{
int x,y;
@@ -306,18 +312,19 @@ void bitmap_dump(struct bitmap *bitmap)
printf("\n");
}
}
+#endif
Object *ami_datatype_object_from_bitmap(struct bitmap *bitmap)
{
Object *dto;
struct BitMapHeader *bmhd;
- if(dto = NewDTObject(NULL,
+ if((dto = NewDTObject(NULL,
DTA_SourceType,DTST_RAM,
DTA_GroupID,GID_PICTURE,
//DTA_BaseName,"ilbm",
PDTA_DestMode,PMODE_V43,
- TAG_DONE))
+ TAG_DONE)))
{
if(GetDTAttrs(dto,PDTA_BitMapHeader,&bmhd,TAG_DONE))
{
diff --git a/amiga/clipboard.c b/amiga/clipboard.c
index fa1d189d4..8631bc498 100644
--- a/amiga/clipboard.c
+++ b/amiga/clipboard.c
@@ -28,13 +28,14 @@
#include "utils/nsoption.h"
#include "utils/utf8.h"
-#include "desktop/gui.h"
#include "desktop/plotters.h"
#include "desktop/textinput.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+#include "desktop/gui_clipboard.h"
#include "amiga/bitmap.h"
#include "amiga/clipboard.h"
-#include "amiga/drag.h"
#include "amiga/filetype.h"
#include "amiga/gui.h"
#include "amiga/iff_cset.h"
@@ -61,11 +62,11 @@ static void ami_clipboard_iffp_clear_stopchunk(struct IFFHandle *iffh, ULONG iff
EntryHandler(iffh, iff_type, iff_chunk, IFFSLI_TOP, &entry_hook, NULL);
}
-struct IFFHandle *ami_clipboard_init_internal(int unit)
+static struct IFFHandle *ami_clipboard_init_internal(int unit)
{
struct IFFHandle *iffhandle = NULL;
- if(iffhandle = AllocIFF())
+ if((iffhandle = AllocIFF()))
{
if(iffhandle->iff_Stream = (ULONG)OpenClipboard(unit))
{
@@ -81,7 +82,7 @@ void ami_clipboard_init(void)
iffh = ami_clipboard_init_internal(0);
}
-void ami_clipboard_free_internal(struct IFFHandle *iffhandle)
+static void ami_clipboard_free_internal(struct IFFHandle *iffhandle)
{
if(iffhandle == NULL) return;
if(iffhandle->iff_Stream) CloseClipboard((struct ClipboardHandle *)iffhandle->iff_Stream);
@@ -106,7 +107,7 @@ void gui_start_selection(struct gui_window *g)
OnMenu(g->shared->win, AMI_MENU_CUT);
}
-char *ami_clipboard_cat_collection(struct CollectionItem *ci, LONG codeset, size_t *text_length)
+static char *ami_clipboard_cat_collection(struct CollectionItem *ci, LONG codeset, size_t *text_length)
{
struct CollectionItem *ci_new = NULL, *ci_next, *ci_curr = ci;
size_t len = 0;
@@ -183,11 +184,11 @@ char *ami_clipboard_cat_collection(struct CollectionItem *ci, LONG codeset, size
return text;
}
-void gui_get_clipboard(char **buffer, size_t *length)
+static void gui_get_clipboard(char **buffer, size_t *length)
{
struct CollectionItem *ci = NULL;
struct StoredProperty *sp = NULL;
- ULONG rlen=0,error;
+ ULONG error;
struct CSet *cset;
if(OpenIFF(iffh,IFFF_READ)) return;
@@ -354,6 +355,7 @@ bool ami_easy_clipboard_bitmap(struct bitmap *bitmap)
DoDTMethod(dto,NULL,NULL,DTM_COPY,NULL);
DisposeDTObject(dto);
}
+ return true;
}
#ifdef WITH_NS_SVG
diff --git a/amiga/context_menu.c b/amiga/context_menu.c
index 5e35f5d0e..a9a5f63f7 100644
--- a/amiga/context_menu.c
+++ b/amiga/context_menu.c
@@ -23,10 +23,21 @@
#include
#include
#include
-
#include
+#include
+
+#include "utils/nsoption.h"
+#include "utils/utf8.h"
+#include "utils/messages.h"
+#include "utils/utils.h"
+#include "render/form.h"
+#include "desktop/browser_history.h"
+#include "desktop/browser_private.h"
+#include "desktop/hotlist.h"
+#include "desktop/searchweb.h"
+#include "desktop/textinput.h"
+#include "desktop/gui_window.h"
-#include "amiga/context_menu.h"
#include "amiga/clipboard.h"
#include "amiga/bitmap.h"
#include "amiga/file.h"
@@ -34,22 +45,12 @@
#include "amiga/gui.h"
#include "amiga/history_local.h"
#include "amiga/iff_dr2d.h"
-#include "utils/nsoption.h"
#include "amiga/plugin_hack.h"
#include "amiga/theme.h"
#include "amiga/tree.h"
#include "amiga/utf8.h"
-#include "desktop/browser_history.h"
-#include "desktop/browser_private.h"
-#include "desktop/hotlist.h"
-#include "desktop/searchweb.h"
-#include "desktop/textinput.h"
-#include "render/form.h"
-#include "utils/utf8.h"
-#include "utils/messages.h"
-#include "utils/utils.h"
+#include "amiga/context_menu.h"
-#include
static uint32 ami_context_menu_hook(struct Hook *hook, Object *item, APTR reserved);
static uint32 ami_context_menu_hook_tree(struct Hook *hook, Object *item, APTR reserved);
@@ -556,8 +557,6 @@ void ami_context_menu_free(void)
BOOL ami_context_menu_mouse_trap(struct gui_window_2 *gwin, BOOL trap)
{
- int top, left, width, height;
-
if(nsoption_bool(context_menu) == false) return FALSE;
if((nsoption_bool(kiosk_mode) == false) && (trap == FALSE))
@@ -584,11 +583,8 @@ BOOL ami_context_menu_mouse_trap(struct gui_window_2 *gwin, BOOL trap)
void ami_context_menu_show(struct gui_window_2 *gwin,int x,int y)
{
struct hlcache_handle *cc = gwin->bw->current_content;
- int box_x=0;
- int box_y=0;
bool no_more_menus = false;
bool menuhascontent = false;
- ULONG ret = 0;
struct contextual_content ccdata;
if(!cc) return;
@@ -734,9 +730,7 @@ static uint32 ami_context_menu_hook(struct Hook *hook,Object *item,APTR reserved
{
struct ami_file_input_menu_data
*file_input = userdata;
- char *utf8_fn;
char fname[1024];
- int x,y;
strlcpy(fname,filereq->fr_Drawer,1024);
AddPart(fname,filereq->fr_File,1024);
diff --git a/amiga/context_menu.h b/amiga/context_menu.h
index 1bd7a84de..c7424c22c 100755
--- a/amiga/context_menu.h
+++ b/amiga/context_menu.h
@@ -18,7 +18,6 @@
#ifndef AMIGA_CONTEXT_MENU_H
#define AMIGA_CONTEXT_MENU_H
-#include "amiga/gui.h"
struct tree;
diff --git a/amiga/cookies.c b/amiga/cookies.c
index e29df343f..0ca17413e 100755
--- a/amiga/cookies.c
+++ b/amiga/cookies.c
@@ -17,8 +17,12 @@
*/
#include
-#include "amiga/cookies.h"
+
#include "desktop/cookie_manager.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/cookies.h"
#include "amiga/tree.h"
void ami_cookies_initialise(void)
diff --git a/amiga/download.c b/amiga/download.c
index 7c0054f03..283fe40bd 100644
--- a/amiga/download.c
+++ b/amiga/download.c
@@ -31,27 +31,6 @@
#include
-#include "amiga/download.h"
-#include "amiga/icon.h"
-#include "amiga/object.h"
-#include "utils/nsoption.h"
-#include "amiga/bitmap.h"
-#include "amiga/iff_dr2d.h"
-#include "amiga/file.h"
-#include "amiga/misc.h"
-#include "amiga/theme.h"
-#include "amiga/utf8.h"
-
-#include "desktop/download.h"
-#include "desktop/save_complete.h"
-
-#include "image/ico.h"
-
-#include "utils/errors.h"
-#include "utils/log.h"
-#include "utils/messages.h"
-#include "utils/utils.h"
-
#include
#include
@@ -62,6 +41,30 @@
#include
+#include "utils/errors.h"
+#include "utils/log.h"
+#include "utils/messages.h"
+#include "utils/utils.h"
+#include "utils/nsoption.h"
+#include "desktop/download.h"
+#include "desktop/save_complete.h"
+#include "desktop/browser.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+#include "desktop/gui_download.h"
+#include "image/ico.h"
+
+#include "amiga/gui.h"
+#include "amiga/download.h"
+#include "amiga/object.h"
+#include "amiga/bitmap.h"
+#include "amiga/icon.h"
+#include "amiga/file.h"
+#include "amiga/drag.h"
+#include "amiga/iff_dr2d.h"
+#include "amiga/misc.h"
+#include "amiga/utf8.h"
+
struct gui_download_window {
struct nsObject *node;
struct Window *win;
diff --git a/amiga/download.h b/amiga/download.h
index 95d71ecfe..7fc722c3d 100755
--- a/amiga/download.h
+++ b/amiga/download.h
@@ -21,8 +21,6 @@
#include "amiga/os3support.h"
-#include "amiga/gui.h"
-
extern struct gui_download_table *amiga_download_table;
struct download_context;
diff --git a/amiga/drag.c b/amiga/drag.c
index c7c5f4b77..a4d2b23d2 100644
--- a/amiga/drag.c
+++ b/amiga/drag.c
@@ -31,19 +31,25 @@
#endif
#include
+#include "utils/errors.h"
+#include "utils/log.h"
+#include "utils/messages.h"
+#include "utils/utils.h"
+#include "utils/nsoption.h"
+#include "desktop/browser.h"
+#include "content/hlcache.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/gui.h"
#include "amiga/bitmap.h"
#include "amiga/clipboard.h"
#include "amiga/download.h"
#include "amiga/drag.h"
#include "amiga/file.h"
#include "amiga/filetype.h"
-#include "utils/nsoption.h"
#include "amiga/theme.h"
-#include "utils/errors.h"
-#include "utils/log.h"
-#include "utils/messages.h"
-#include "utils/utils.h"
struct Window *drag_icon = NULL;
ULONG drag_icon_width;
diff --git a/amiga/drag.h b/amiga/drag.h
index cfe9719ce..2b3cfd2ef 100644
--- a/amiga/drag.h
+++ b/amiga/drag.h
@@ -18,7 +18,6 @@
#ifndef AMIGA_DRAG_H
#define AMIGA_DRAG_H
-#include "amiga/gui.h"
#define AMI_DRAG_THRESHOLD 10
diff --git a/amiga/file.c b/amiga/file.c
index b73dd1676..dc283a45f 100644
--- a/amiga/file.c
+++ b/amiga/file.c
@@ -16,6 +16,24 @@
* along with this program. If not, see .
*/
+#include
+#include
+#include
+#include
+#include
+
+#include "utils/nsoption.h"
+#include "utils/file.h"
+#include "utils/messages.h"
+#include "content/content.h"
+#include "content/fetch.h"
+#include "desktop/browser_private.h"
+#include "desktop/save_complete.h"
+#include "desktop/save_pdf/pdf_plotters.h"
+#include "desktop/save_text.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/gui.h"
#include "amiga/bitmap.h"
#include "amiga/download.h"
#include "amiga/file.h"
@@ -26,24 +44,6 @@
#include "amiga/save_pdf.h"
#include "amiga/theme.h"
-#include "content/content.h"
-#include "content/fetch.h"
-
-#include "desktop/browser_private.h"
-#include "utils/nsoption.h"
-#include "utils/file.h"
-#include "desktop/save_complete.h"
-#include "desktop/save_pdf/pdf_plotters.h"
-#include "desktop/save_text.h"
-
-#include "utils/messages.h"
-
-#include
-#include
-#include
-#include
-#include
-
static struct Hook aslhookfunc;
static const ULONG ami_file_asl_mime_hook(struct Hook *mh,
diff --git a/amiga/file.h b/amiga/file.h
index 904de69fe..075e10e7e 100644
--- a/amiga/file.h
+++ b/amiga/file.h
@@ -16,7 +16,6 @@
* along with this program. If not, see .
*/
-#include "amiga/gui.h"
struct hlcache_object;
struct selection;
diff --git a/amiga/font.c b/amiga/font.c
index 711aeb67d..c6805e8d4 100755
--- a/amiga/font.c
+++ b/amiga/font.c
@@ -18,19 +18,6 @@
#include
-#include "amiga/font.h"
-#include "amiga/font_scan.h"
-#include "amiga/gui.h"
-#include "amiga/utf8.h"
-#include "amiga/object.h"
-#include "amiga/schedule.h"
-#include "utils/nsoption.h"
-#include "desktop/browser.h"
-#include "desktop/font.h"
-#include "utils/log.h"
-#include "utils/utf8.h"
-#include "utils/utils.h"
-
#include
#include
#include
@@ -46,6 +33,21 @@
#include
#endif
+#include "utils/log.h"
+#include "utils/utf8.h"
+#include "utils/utils.h"
+#include "utils/nsoption.h"
+#include "desktop/browser.h"
+#include "desktop/font.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/font.h"
+#include "amiga/font_scan.h"
+#include "amiga/gui.h"
+#include "amiga/utf8.h"
+#include "amiga/object.h"
+#include "amiga/schedule.h"
+
#define NSA_UNICODE_FONT PLOT_FONT_FAMILY_COUNT
#define NSA_NORMAL 0
diff --git a/amiga/font_scan.c b/amiga/font_scan.c
index 6a595b456..7720c6383 100644
--- a/amiga/font_scan.c
+++ b/amiga/font_scan.c
@@ -40,15 +40,17 @@
#include
+#include "utils/nsoption.h"
+#include "utils/log.h"
+#include "utils/messages.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
#include "amiga/font_scan.h"
#include "amiga/gui.h"
#include "amiga/object.h"
#include "amiga/utf8.h"
-#include "utils/nsoption.h"
-#include "utils/log.h"
-#include "utils/messages.h"
-
enum {
FS_OID_MAIN = 0,
FS_GID_MAIN,
diff --git a/amiga/gui.c b/amiga/gui.c
index 354a3e1b0..6df5def83 100644
--- a/amiga/gui.c
+++ b/amiga/gui.c
@@ -16,63 +16,7 @@
* along with this program. If not, see .
*/
-/* NetSurf core includes */
-#include "content/backing_store.h"
-#include "content/fetchers.h"
-#include "content/fetchers/resource.h"
-#include "content/urldb.h"
-#include "desktop/browser_history.h"
-#include "desktop/browser_private.h"
-#include "desktop/hotlist.h"
-#include "desktop/mouse.h"
-#include "desktop/netsurf.h"
-#include "desktop/version.h"
-#include "desktop/save_complete.h"
-#include "desktop/scrollbar.h"
-#include "desktop/searchweb.h"
-#include "desktop/textinput.h"
-#include "desktop/tree.h"
-#include "image/ico.h"
-#include "utils/log.h"
-#include "utils/messages.h"
-#include "utils/nsoption.h"
-#include "utils/utf8.h"
-#include "utils/utils.h"
-#include "utils/nsurl.h"
-#include "utils/file.h"
-/* NetSurf Amiga platform includes */
-#include "amiga/arexx.h"
-#include "amiga/bitmap.h"
-#include "amiga/clipboard.h"
-#include "amiga/context_menu.h"
-#include "amiga/cookies.h"
-#include "amiga/datatypes.h"
-#include "amiga/download.h"
-#include "amiga/drag.h"
-#include "amiga/file.h"
-#include "amiga/filetype.h"
-#include "amiga/font.h"
-#include "amiga/gui.h"
-#include "amiga/gui_options.h"
-#include "amiga/help.h"
-#include "amiga/history.h"
-#include "amiga/history_local.h"
-#include "amiga/hotlist.h"
-#include "amiga/icon.h"
-#include "amiga/launch.h"
-#include "amiga/login.h"
-#include "amiga/menu.h"
-#include "amiga/misc.h"
-#include "amiga/plotters.h"
-#include "amiga/plugin_hack.h"
-#include "amiga/print.h"
-#include "amiga/schedule.h"
-#include "amiga/search.h"
-#include "amiga/theme.h"
-#include "amiga/tree.h"
-#include "amiga/utf8.h"
-#include "amiga/sslcert.h"
/* Custom StringView class */
#include "amiga/stringview/stringview.h"
@@ -140,6 +84,67 @@
#include
#include
+/* NetSurf core includes */
+#include "utils/log.h"
+#include "utils/messages.h"
+#include "utils/nsoption.h"
+#include "utils/utf8.h"
+#include "utils/utils.h"
+#include "utils/nsurl.h"
+#include "utils/file.h"
+#include "content/backing_store.h"
+#include "content/fetchers.h"
+#include "content/fetchers/resource.h"
+#include "content/urldb.h"
+#include "image/ico.h"
+#include "desktop/browser_history.h"
+#include "desktop/browser_private.h"
+#include "desktop/hotlist.h"
+#include "desktop/mouse.h"
+#include "desktop/netsurf.h"
+#include "desktop/version.h"
+#include "desktop/save_complete.h"
+#include "desktop/scrollbar.h"
+#include "desktop/searchweb.h"
+#include "desktop/textinput.h"
+#include "desktop/tree.h"
+#include "desktop/gui_window.h"
+#include "desktop/gui_fetch.h"
+#include "desktop/gui_misc.h"
+
+/* NetSurf Amiga platform includes */
+#include "amiga/gui.h"
+#include "amiga/arexx.h"
+#include "amiga/bitmap.h"
+#include "amiga/clipboard.h"
+#include "amiga/context_menu.h"
+#include "amiga/cookies.h"
+#include "amiga/datatypes.h"
+#include "amiga/download.h"
+#include "amiga/drag.h"
+#include "amiga/file.h"
+#include "amiga/filetype.h"
+#include "amiga/font.h"
+#include "amiga/gui_options.h"
+#include "amiga/help.h"
+#include "amiga/history.h"
+#include "amiga/history_local.h"
+#include "amiga/hotlist.h"
+#include "amiga/icon.h"
+#include "amiga/launch.h"
+#include "amiga/login.h"
+#include "amiga/menu.h"
+#include "amiga/misc.h"
+#include "amiga/plotters.h"
+#include "amiga/plugin_hack.h"
+#include "amiga/print.h"
+#include "amiga/schedule.h"
+#include "amiga/search.h"
+#include "amiga/theme.h"
+#include "amiga/tree.h"
+#include "amiga/utf8.h"
+#include "amiga/sslcert.h"
+
#define AMINS_SCROLLERPEN NUMDRIPENS
#define NSA_KBD_SCROLL_PX 10
@@ -307,7 +312,7 @@ bool ami_gui_map_filename(char **remapped, const char *path, const char *file, c
return found;
}
-bool ami_gui_check_resource(char *fullpath, const char *file)
+static bool ami_gui_check_resource(char *fullpath, const char *file)
{
bool found = false;
char *remapped;
@@ -400,7 +405,7 @@ bool ami_locate_resource(char *fullpath, const char *file)
return found;
}
-void ami_open_resources(void)
+static void ami_open_resources(void)
{
/* Allocate ports/ASL and open libraries and devices */
@@ -608,7 +613,7 @@ static nserror ami_set_options(struct nsoption_s *defaults)
return NSERROR_OK;
}
-void ami_amiupdate(void)
+static void ami_amiupdate(void)
{
/* Create AppPath location for AmiUpdate use */
@@ -663,7 +668,7 @@ static nsurl *gui_get_resource_url(const char *path)
return url;
}
-void gui_init(int argc, char** argv)
+static void gui_init(int argc, char** argv)
{
BPTR lock = 0;
@@ -696,7 +701,7 @@ static void ami_gui_newprefs_hook(struct Hook *hook, APTR window, APTR reserved)
ami_set_screen_defaults(scrn);
}
-void ami_openscreen(void)
+static void ami_openscreen(void)
{
ULONG id = 0;
ULONG compositing;
@@ -783,7 +788,7 @@ void ami_openscreen(void)
ami_help_new_screen(scrn);
}
-void ami_openscreenfirst(void)
+static void ami_openscreenfirst(void)
{
ami_openscreen();
if(!browserglob.bm) ami_init_layers(&browserglob, 0, 0);
@@ -1155,7 +1160,7 @@ int ami_key_to_nskey(ULONG keycode, struct InputEvent *ie)
return nskey;
}
-void ami_update_quals(struct gui_window_2 *gwin)
+static void ami_update_quals(struct gui_window_2 *gwin)
{
uint32 quals = 0;
@@ -1179,7 +1184,7 @@ void ami_update_quals(struct gui_window_2 *gwin)
}
}
-bool ami_spacebox_to_ns_coords(struct gui_window_2 *gwin, int *x, int *y,
+static bool ami_spacebox_to_ns_coords(struct gui_window_2 *gwin, int *x, int *y,
int space_x, int space_y)
{
int ns_x = space_x;
@@ -1197,7 +1202,7 @@ bool ami_spacebox_to_ns_coords(struct gui_window_2 *gwin, int *x, int *y,
return true;
}
-bool ami_mouse_to_ns_coords(struct gui_window_2 *gwin, int *x, int *y,
+static bool ami_mouse_to_ns_coords(struct gui_window_2 *gwin, int *x, int *y,
int mouse_x, int mouse_y)
{
int ns_x, ns_y;
@@ -1218,7 +1223,7 @@ bool ami_mouse_to_ns_coords(struct gui_window_2 *gwin, int *x, int *y,
return ami_spacebox_to_ns_coords(gwin, x, y, ns_x, ns_y);
}
-void ami_gui_scroll_internal(struct gui_window_2 *gwin, int xs, int ys)
+static void ami_gui_scroll_internal(struct gui_window_2 *gwin, int xs, int ys)
{
struct IBox *bbox;
int x, y;
@@ -1287,7 +1292,7 @@ void ami_gui_scroll_internal(struct gui_window_2 *gwin, int xs, int ys)
}
}
-struct IBox *ami_ns_rect_to_ibox(struct gui_window_2 *gwin, const struct rect *rect)
+static struct IBox *ami_ns_rect_to_ibox(struct gui_window_2 *gwin, const struct rect *rect)
{
struct IBox *bbox, *ibox;
@@ -1316,7 +1321,7 @@ struct IBox *ami_ns_rect_to_ibox(struct gui_window_2 *gwin, const struct rect *r
return ibox;
}
-void ami_gui_trap_mouse(struct gui_window_2 *gwin)
+static void ami_gui_trap_mouse(struct gui_window_2 *gwin)
{
switch(gwin->drag_op)
{
@@ -1335,7 +1340,7 @@ void ami_gui_trap_mouse(struct gui_window_2 *gwin)
}
}
-void ami_gui_menu_update_all(void)
+static void ami_gui_menu_update_all(void)
{
struct nsObject *node;
struct nsObject *nnode;
@@ -1425,7 +1430,7 @@ static void ami_gui_refresh_favicon(void *p)
gui_window_set_icon(gwin->bw->window, gwin->bw->window->favicon);
}
-void ami_handle_msg(void)
+static void ami_handle_msg(void)
{
ULONG class,result,storage = 0,x,y,xs,ys,width=800,height=600;
uint16 code,quals;
@@ -2225,7 +2230,7 @@ void ami_handle_msg(void)
}
}
-void ami_gui_appicon_remove(struct gui_window_2 *gwin)
+static void ami_gui_appicon_remove(struct gui_window_2 *gwin)
{
if(gwin->appicon)
{
@@ -2235,7 +2240,7 @@ void ami_gui_appicon_remove(struct gui_window_2 *gwin)
}
}
-void ami_handle_appmsg(void)
+static void ami_handle_appmsg(void)
{
struct AppMessage *appmsg;
struct gui_window_2 *gwin;
@@ -2350,7 +2355,7 @@ void ami_handle_appmsg(void)
}
}
-void ami_handle_applib(void)
+static void ami_handle_applib(void)
{
struct ApplicationMsg *applibmsg;
struct browser_window *bw;
@@ -2655,7 +2660,7 @@ void ami_quit_netsurf_delayed(void)
}
}
-void ami_gui_close_screen(struct Screen *scrn, BOOL locked_screen, BOOL donotwait)
+static void ami_gui_close_screen(struct Screen *scrn, BOOL locked_screen, BOOL donotwait)
{
if(scrn == NULL) return;
if(CloseScreen(scrn) == TRUE) {
@@ -2895,7 +2900,7 @@ static bool ami_gui_hotlist_add(void *userdata, int level, int item, const char
return true;
}
-int ami_gui_hotlist_scan(struct tree *tree, struct List *speed_button_list, struct gui_window_2 *gwin)
+static int ami_gui_hotlist_scan(struct tree *tree, struct List *speed_button_list, struct gui_window_2 *gwin)
{
struct ami_gui_tb_userdata userdata;
userdata.gw = gwin;
@@ -2906,7 +2911,7 @@ int ami_gui_hotlist_scan(struct tree *tree, struct List *speed_button_list, stru
return userdata.items;
}
-void ami_gui_hotlist_toolbar_add(struct gui_window_2 *gwin)
+static void ami_gui_hotlist_toolbar_add(struct gui_window_2 *gwin)
{
struct TagItem attrs[2];
diff --git a/amiga/gui.h b/amiga/gui.h
index c106455d1..057124c3d 100755
--- a/amiga/gui.h
+++ b/amiga/gui.h
@@ -24,7 +24,6 @@
#include "desktop/browser.h"
#include
#include
-#include "desktop/gui.h"
#include "amiga/os3support.h"
#include "amiga/plotters.h"
#include "amiga/menu.h"
diff --git a/amiga/gui_options.c b/amiga/gui_options.c
index 50f7b7cfd..04beb81af 100755
--- a/amiga/gui_options.c
+++ b/amiga/gui_options.c
@@ -29,18 +29,6 @@
#include
#include
-#include "amiga/object.h"
-#include "amiga/font.h"
-#include "amiga/gui.h"
-#include "amiga/gui_options.h"
-#include "amiga/help.h"
-#include "amiga/theme.h"
-#include "amiga/utf8.h"
-#include "utils/messages.h"
-#include "desktop/browser_private.h"
-#include "utils/nsoption.h"
-#include "desktop/searchweb.h"
-
#include
#include
#include
@@ -69,6 +57,20 @@
#include
#include
+#include "utils/messages.h"
+#include "utils/nsoption.h"
+#include "desktop/browser_private.h"
+#include "desktop/searchweb.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/object.h"
+#include "amiga/font.h"
+#include "amiga/gui.h"
+#include "amiga/gui_options.h"
+#include "amiga/help.h"
+#include "amiga/theme.h"
+#include "amiga/utf8.h"
+
enum
{
GID_OPTS_MAIN = GID_MAIN,
@@ -218,7 +220,7 @@ CONST_STRPTR fontopts[6];
CONST_STRPTR gadlab[OPTS_LAST];
struct List *websearch_list;
-void ami_gui_opts_setup(void)
+static void ami_gui_opts_setup(void)
{
tabs[0] = (char *)ami_utf8_easy((char *)messages_get("con_general"));
tabs[1] = (char *)ami_utf8_easy((char *)messages_get("Display"));
@@ -372,7 +374,7 @@ void ami_gui_opts_setup(void)
fontopts[5] = NULL;
}
-void ami_gui_opts_free(void)
+static void ami_gui_opts_free(void)
{
int i;
@@ -1530,7 +1532,7 @@ void ami_gui_opts_open(void)
ami_utf8_free(homepage_url_lc);
}
-void ami_gui_opts_use(bool save)
+static void ami_gui_opts_use(bool save)
{
ULONG data, id = 0;
float animspeed;
@@ -1701,31 +1703,31 @@ void ami_gui_opts_use(bool save)
GetAttr(GETFONT_TextAttr,gow->objects[GID_OPTS_FONT_SANS],(ULONG *)&data);
tattr = (struct TextAttr *)data;
- if(dot = strrchr(tattr->ta_Name,'.')) *dot = '\0';
+ if((dot = strrchr(tattr->ta_Name,'.'))) *dot = '\0';
nsoption_set_charp(font_sans, (char *)strdup((char *)tattr->ta_Name));
GetAttr(GETFONT_TextAttr,gow->objects[GID_OPTS_FONT_SERIF],(ULONG *)&data);
tattr = (struct TextAttr *)data;
- if(dot = strrchr(tattr->ta_Name,'.')) *dot = '\0';
+ if((dot = strrchr(tattr->ta_Name,'.'))) *dot = '\0';
nsoption_set_charp(font_serif, (char *)strdup((char *)tattr->ta_Name));
GetAttr(GETFONT_TextAttr,gow->objects[GID_OPTS_FONT_MONO],(ULONG *)&data);
tattr = (struct TextAttr *)data;
- if(dot = strrchr(tattr->ta_Name,'.')) *dot = '\0';
+ if((dot = strrchr(tattr->ta_Name,'.'))) *dot = '\0';
nsoption_set_charp(font_mono, (char *)strdup((char *)tattr->ta_Name));
GetAttr(GETFONT_TextAttr,gow->objects[GID_OPTS_FONT_CURSIVE],(ULONG *)&data);
tattr = (struct TextAttr *)data;
- if(dot = strrchr(tattr->ta_Name,'.')) *dot = '\0';
+ if((dot = strrchr(tattr->ta_Name,'.'))) *dot = '\0';
nsoption_set_charp(font_cursive, (char *)strdup((char *)tattr->ta_Name));
GetAttr(GETFONT_TextAttr,gow->objects[GID_OPTS_FONT_FANTASY],(ULONG *)&data);
tattr = (struct TextAttr *)data;
- if(dot = strrchr(tattr->ta_Name,'.')) *dot = '\0';
+ if((dot = strrchr(tattr->ta_Name,'.'))) *dot = '\0';
nsoption_set_charp(font_fantasy, (char *)strdup((char *)tattr->ta_Name));
GetAttr(CHOOSER_Selected,gow->objects[GID_OPTS_FONT_DEFAULT],(ULONG *)&nsoption_int(font_default));
@@ -2148,7 +2150,7 @@ void ami_gui_opts_websearch_free(struct List *websearchlist)
do {
nnode = GetSucc(node);
Remove(node);
- } while(node = nnode);
+ } while((node = nnode));
FreeVec(websearchlist);
}
diff --git a/amiga/history.c b/amiga/history.c
index 663c2d910..63e011bc4 100755
--- a/amiga/history.c
+++ b/amiga/history.c
@@ -16,9 +16,14 @@
* along with this program. If not, see .
*/
+#include
+#include
+
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
#include "amiga/history.h"
#include "amiga/tree.h"
-#include
#include "amiga/tree.h"
void ami_global_history_initialise(void)
diff --git a/amiga/history_local.c b/amiga/history_local.c
index 9884ea3ec..bd19ba657 100755
--- a/amiga/history_local.c
+++ b/amiga/history_local.c
@@ -25,23 +25,11 @@
#include
#include
#include
-#include "desktop/browser_history.h"
-#include "desktop/browser_private.h"
-#include "desktop/plotters.h"
-#include "amiga/os3support.h"
-#include "amiga/object.h"
-#include "amiga/gui.h"
-#include "utils/log.h"
-#include "utils/utils.h"
#include
-#include "amiga/history_local.h"
#include
#include
#include
#include
-#include "utils/messages.h"
-#include "graphics/rpattr.h"
-
#include
#include
#include
@@ -51,11 +39,22 @@
#include
#include
+#include "utils/log.h"
+#include "utils/utils.h"
+#include "utils/messages.h"
+#include "desktop/browser_history.h"
+#include "desktop/browser_private.h"
+#include "desktop/plotters.h"
+#include "desktop/gui_window.h"
+#include "graphics/rpattr.h"
+
+#include "amiga/os3support.h"
+#include "amiga/object.h"
+#include "amiga/gui.h"
+#include "amiga/history_local.h"
+
+
static struct browser_window *history_bw;
-/* Last position of mouse in window. */
-static int mouse_x = 0;
-/* Last position of mouse in window. */
-static int mouse_y = 0;
static struct history_window *hwindow;
void ami_history_update_extent(struct history_window *hw);
@@ -189,7 +188,7 @@ void ami_history_redraw(struct history_window *hw)
* \return true if the event was handled, false to pass it on
*/
-bool ami_history_click(struct history_window *hw,uint16 code)
+static bool ami_history_click(struct history_window *hw,uint16 code)
{
int x, y;
struct IBox *bbox;
@@ -235,7 +234,7 @@ void ami_history_close(struct history_window *hw)
BOOL ami_history_event(struct history_window *hw)
{
/* return TRUE if window destroyed */
- ULONG class,result,relevent = 0;
+ ULONG result = 0;
uint16 code;
const char *url;
struct IBox *bbox;
@@ -316,7 +315,7 @@ void ami_history_update_extent(struct history_window *hw)
void ami_history_scroller_hook(struct Hook *hook,Object *object,struct IntuiMessage *msg)
{
- ULONG gid,x,y;
+ ULONG gid;
struct history_window *hw = hook->h_Data;
if (msg->Class == IDCMP_IDCMPUPDATE)
diff --git a/amiga/hotlist.c b/amiga/hotlist.c
index b67ba22af..834587ef2 100755
--- a/amiga/hotlist.c
+++ b/amiga/hotlist.c
@@ -17,9 +17,13 @@
*/
#include
+
+#include "desktop/hotlist.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
#include "amiga/hotlist.h"
#include "amiga/tree.h"
-#include "desktop/hotlist.h"
struct ami_hotlist_ctx {
void *userdata;
diff --git a/amiga/login.c b/amiga/login.c
index c4bf5d92a..954c58b76 100755
--- a/amiga/login.c
+++ b/amiga/login.c
@@ -16,16 +16,9 @@
* along with this program. If not, see .
*/
-#include "amiga/os3support.h"
-#include "amiga/gui.h"
-#include "amiga/object.h"
-#include "amiga/login.h"
#include
#include
#include
-#include "content/urldb.h"
-#include "utils/messages.h"
-#include "utils/errors.h"
#include
#include
@@ -40,6 +33,17 @@
#include
#include
+#include "utils/messages.h"
+#include "utils/errors.h"
+#include "content/urldb.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/os3support.h"
+#include "amiga/gui.h"
+#include "amiga/object.h"
+#include "amiga/login.h"
+
struct gui_login_window {
struct nsObject *node;
struct Window *win;
diff --git a/amiga/menu.c b/amiga/menu.c
index d3af00ee3..493d5f144 100644
--- a/amiga/menu.c
+++ b/amiga/menu.c
@@ -39,12 +39,13 @@
#include
#include "utils/nsoption.h"
+#include "utils/messages.h"
#include "desktop/hotlist.h"
#include "desktop/browser_private.h"
-#include "desktop/gui.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
#include "desktop/textinput.h"
#include "desktop/version.h"
-#include "utils/messages.h"
#include "amiga/arexx.h"
#include "amiga/bitmap.h"
diff --git a/amiga/misc.c b/amiga/misc.c
index 7b42dc9a5..3bd493745 100755
--- a/amiga/misc.c
+++ b/amiga/misc.c
@@ -32,9 +32,6 @@
#include
#include
-#include "amiga/gui.h"
-#include "amiga/utf8.h"
-#include "desktop/cookie_manager.h"
#include "utils/log.h"
#include "utils/corestrings.h"
#include "utils/messages.h"
@@ -42,6 +39,13 @@
#include "utils/file.h"
#include "utils/utils.h"
+#include "desktop/cookie_manager.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/gui.h"
+#include "amiga/utf8.h"
+
void warn_user(const char *warning, const char *detail)
{
Object *req = NULL;
diff --git a/amiga/plotters.c b/amiga/plotters.c
index cb7ccac78..eecc15f35 100755
--- a/amiga/plotters.c
+++ b/amiga/plotters.c
@@ -16,17 +16,6 @@
* along with this program. If not, see .
*/
-#include "amiga/plotters.h"
-#include "amiga/bitmap.h"
-#include "amiga/font.h"
-#include "amiga/gui.h"
-#include "amiga/utf8.h"
-
-#include "css/utils.h"
-#include "utils/nsoption.h"
-#include "utils/utils.h"
-#include "utils/log.h"
-
#include
#include
#include
@@ -44,6 +33,19 @@
#include
#include
+#include "utils/nsoption.h"
+#include "utils/utils.h"
+#include "utils/log.h"
+#include "css/utils.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/plotters.h"
+#include "amiga/bitmap.h"
+#include "amiga/font.h"
+#include "amiga/gui.h"
+#include "amiga/utf8.h"
+
static void ami_bitmap_tile_hook(struct Hook *hook,struct RastPort *rp,struct BackFillMessage *bfmsg);
struct bfbitmap {
diff --git a/amiga/print.c b/amiga/print.c
index 19c78d097..5496eed7c 100644
--- a/amiga/print.c
+++ b/amiga/print.c
@@ -16,16 +16,6 @@
* along with this program. If not, see .
*/
-#include "desktop/printer.h"
-#include "amiga/plotters.h"
-#include "desktop/font.h"
-#include "amiga/gui.h"
-#include "utils/nsoption.h"
-#include "amiga/print.h"
-#include "utils/messages.h"
-#include "utils/utils.h"
-#include "amiga/utf8.h"
-
#include
#include
#include
@@ -53,6 +43,19 @@
#include
+#include "utils/nsoption.h"
+#include "utils/messages.h"
+#include "utils/utils.h"
+#include "desktop/printer.h"
+#include "desktop/font.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/plotters.h"
+#include "amiga/gui.h"
+#include "amiga/print.h"
+#include "amiga/utf8.h"
+
bool ami_print_begin(struct print_settings *ps);
bool ami_print_next_page(void);
void ami_print_end(void);
diff --git a/amiga/search.c b/amiga/search.c
index 53754145a..daf2db121 100755
--- a/amiga/search.c
+++ b/amiga/search.c
@@ -25,17 +25,6 @@
#include "utils/config.h"
#include
#include
-#include "content/content.h"
-#include "desktop/browser.h"
-#include "desktop/gui.h"
-#include "desktop/search.h"
-#include "utils/log.h"
-#include "utils/messages.h"
-#include "utils/utils.h"
-#include "amiga/os3support.h"
-#include "amiga/search.h"
-#include "amiga/object.h"
-#include "amiga/theme.h"
#include
#include
@@ -53,6 +42,21 @@
#include
#include
+#include "utils/log.h"
+#include "utils/messages.h"
+#include "utils/utils.h"
+#include "content/content.h"
+#include "desktop/browser.h"
+#include "desktop/search.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+#include "desktop/gui_search.h"
+
+#include "amiga/os3support.h"
+#include "amiga/search.h"
+#include "amiga/object.h"
+#include "amiga/theme.h"
+
#ifndef NOF_ELEMENTS
#define NOF_ELEMENTS(array) (sizeof(array)/sizeof(*(array)))
#endif
diff --git a/amiga/sslcert.c b/amiga/sslcert.c
index 3c83df138..699ce71b8 100644
--- a/amiga/sslcert.c
+++ b/amiga/sslcert.c
@@ -17,9 +17,15 @@
*/
#include
+
+#include "utils/nsurl.h"
+#include "content/llcache.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+#include "desktop/sslcert_viewer.h"
+
#include "amiga/tree.h"
#include "amiga/sslcert.h"
-#include "desktop/sslcert_viewer.h"
void gui_cert_verify(nsurl *url,
const struct ssl_cert_info *certs, unsigned long num,
diff --git a/amiga/theme.c b/amiga/theme.c
index cc8b55d7f..047a86e8c 100644
--- a/amiga/theme.c
+++ b/amiga/theme.c
@@ -34,15 +34,19 @@
#include
#include
-#include "amiga/bitmap.h"
-#include "amiga/drag.h"
-#include "amiga/schedule.h"
-#include "amiga/theme.h"
-#include "desktop/browser_private.h"
-#include "desktop/searchweb.h"
#include "utils/messages.h"
#include "utils/nsoption.h"
#include "utils/utils.h"
+#include "desktop/browser_private.h"
+#include "desktop/searchweb.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/gui.h"
+#include "amiga/drag.h"
+#include "amiga/bitmap.h"
+#include "amiga/schedule.h"
+#include "amiga/theme.h"
struct BitMap *throbber = NULL;
struct bitmap *throbber_nsbm = NULL;
diff --git a/amiga/theme.h b/amiga/theme.h
index c1aca15d7..083220efc 100644
--- a/amiga/theme.h
+++ b/amiga/theme.h
@@ -18,7 +18,6 @@
#ifndef AMIGA_THEME_H
#define AMIGA_THEME_H
-#include "amiga/gui.h"
#define AMI_GUI_POINTER_BLANK GUI_POINTER_PROGRESS+1
#define AMI_GUI_POINTER_DRAG GUI_POINTER_PROGRESS+2
diff --git a/amiga/thumbnail.c b/amiga/thumbnail.c
index 9c149129d..02b0aba51 100755
--- a/amiga/thumbnail.c
+++ b/amiga/thumbnail.c
@@ -16,15 +16,6 @@
* along with this program. If not, see .
*/
-#include "amiga/os3support.h"
-#include "desktop/browser.h"
-#include "amiga/gui.h"
-#include "amiga/bitmap.h"
-#include "utils/nsoption.h"
-#include "content/urldb.h"
-#include "desktop/plotters.h"
-#include "desktop/thumbnail.h"
-
#include
#include
#include
@@ -36,6 +27,18 @@
#include
+#include "amiga/os3support.h"
+#include "desktop/browser.h"
+#include "utils/nsoption.h"
+#include "content/urldb.h"
+#include "desktop/plotters.h"
+#include "desktop/thumbnail.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+
+#include "amiga/gui.h"
+#include "amiga/bitmap.h"
+
bool thumbnail_create(hlcache_handle *content, struct bitmap *bitmap,
nsurl *url)
{
diff --git a/amiga/tree.c b/amiga/tree.c
index 18b071de3..ce922f83e 100644
--- a/amiga/tree.c
+++ b/amiga/tree.c
@@ -44,27 +44,30 @@
#include
#include
-#include "amiga/context_menu.h"
-#include "amiga/file.h"
+#include
+#include
+
+#include "utils/nsoption.h"
+#include "utils/utils.h"
+#include "utils/messages.h"
+#include "content/urldb.h"
+#include "content/llcache.h"
+#include "desktop/cookie_manager.h"
+#include "desktop/global_history.h"
+#include "desktop/hotlist.h"
+#include "desktop/mouse.h"
+#include "desktop/gui_window.h"
+#include "desktop/sslcert_viewer.h"
+
#include "amiga/gui.h"
#include "amiga/tree.h"
+#include "amiga/file.h"
#include "amiga/utf8.h"
#include "amiga/sslcert.h"
#include "amiga/drag.h" /* drag icon stuff */
#include "amiga/theme.h" /* pointers */
#include "amiga/filetype.h"
#include "amiga/schedule.h"
-#include "utils/nsoption.h"
-#include "content/urldb.h"
-#include "desktop/cookie_manager.h"
-#include "desktop/global_history.h"
-#include "desktop/hotlist.h"
-#include "desktop/sslcert_viewer.h"
-#include "utils/utils.h"
-#include "utils/messages.h"
-
-#include
-#include
#define AMI_TREE_MENU_ITEMS 24
#define AMI_TREE_MENU_NEWDIR FULLMENUNUM(1,0,0)
diff --git a/amiga/tree.h b/amiga/tree.h
index d8d50fe1a..39a71d70d 100755
--- a/amiga/tree.h
+++ b/amiga/tree.h
@@ -22,7 +22,6 @@
#include
#include
#include "amiga/os3support.h"
-#include "amiga/gui.h"
#include "desktop/tree.h"
struct treeview_window;
diff --git a/amiga/utf8.c b/amiga/utf8.c
index a8e415d45..9bf1b1adb 100755
--- a/amiga/utf8.c
+++ b/amiga/utf8.c
@@ -19,13 +19,13 @@
#include
#include
#include
-
-#include "utils/utf8.h"
-#include "desktop/gui.h"
#include
#include
#include
+#include "utils/utf8.h"
+#include "desktop/gui_utf8.h"
+
#include "amiga/utf8.h"
nserror utf8_from_local_encoding(const char *string, size_t len, char **result)