summaryrefslogtreecommitdiff
path: root/riscos
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2004-09-13 23:59:30 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2004-09-13 23:59:30 +0000
commitb74184c2476b5c3559f744ae9ddd36c702657a95 (patch)
treef461cfd43d94d609494a208f2503f0f795ace6e2 /riscos
parent8f9221c6ca943606872c53d6abae5e03431ea56f (diff)
downloadnetsurf-b74184c2476b5c3559f744ae9ddd36c702657a95.tar.gz
netsurf-b74184c2476b5c3559f744ae9ddd36c702657a95.tar.bz2
[project @ 2004-09-13 23:59:30 by jmb]
Add some #defines svn path=/import/netsurf/; revision=1276
Diffstat (limited to 'riscos')
-rw-r--r--riscos/filetype.c15
-rw-r--r--riscos/print.c10
-rw-r--r--riscos/url_protocol.c3
-rw-r--r--riscos/window.c6
4 files changed, 28 insertions, 6 deletions
diff --git a/riscos/filetype.c b/riscos/filetype.c
index 039d26348..5ce3dd0e5 100644
--- a/riscos/filetype.c
+++ b/riscos/filetype.c
@@ -13,6 +13,7 @@
#include "netsurf/content/content.h"
#include "netsurf/content/fetch.h"
#include "netsurf/riscos/gui.h"
+#include "netsurf/utils/config.h"
#include "netsurf/utils/log.h"
#include "netsurf/utils/utils.h"
@@ -124,14 +125,26 @@ int ro_content_filetype(struct content *content)
switch (content->type) {
case CONTENT_HTML: return 0xfaf;
case CONTENT_TEXTPLAIN: return 0xfff;
- case CONTENT_MNG: return 0xf84;
case CONTENT_CSS: return 0xf79;
+#ifdef WITH_MNG
case CONTENT_JNG: return 0xf78;
+ case CONTENT_MNG: return 0xf84;
+#endif
+#ifdef WITH_JPEG
case CONTENT_JPEG: return 0xc85;
+#endif
+#ifdef WITH_PNG
case CONTENT_PNG: return 0xb60;
+#endif
+#ifdef WITH_GIF
case CONTENT_GIF: return 0x695;
+#endif
+#ifdef WITH_SPRITE
case CONTENT_SPRITE: return 0xff9;
+#endif
+#ifdef WITH_DRAW
case CONTENT_DRAW: return 0xaff;
+#endif
default: break;
}
diff --git a/riscos/print.c b/riscos/print.c
index 573ae50a3..336863a7c 100644
--- a/riscos/print.c
+++ b/riscos/print.c
@@ -33,14 +33,14 @@
* \todo make use of print stylesheets
*/
-#ifdef WITH_PRINT
-
-/* 1 millipoint == 1/400 OS unit = 1/800 browser units */
-
/* extern globals */
struct gui_window *print_current_window = 0;
-bool print_active = false;
bool print_text_black = false;
+bool print_active = false;
+
+#ifdef WITH_PRINT
+
+/* 1 millipoint == 1/400 OS unit = 1/800 browser units */
/* static globals */
static int print_prev_message = 0;
diff --git a/riscos/url_protocol.c b/riscos/url_protocol.c
index 7a95b1753..857e43a25 100644
--- a/riscos/url_protocol.c
+++ b/riscos/url_protocol.c
@@ -28,6 +28,7 @@
#include "netsurf/utils/log.h"
#include "netsurf/utils/utils.h"
+#ifdef WITH_URL
/**
* Handle a Message_InetSuiteOpenURL.
@@ -190,3 +191,5 @@ void ro_url_bounce(wimp_message *message)
/* ant broadcast bounced -> try uri broadcast / load */
ro_uri_launch(url_message->url);
}
+
+#endif
diff --git a/riscos/window.c b/riscos/window.c
index 4327e47a5..0ca060353 100644
--- a/riscos/window.c
+++ b/riscos/window.c
@@ -1100,9 +1100,11 @@ void ro_gui_toolbar_click(struct gui_window *g, wimp_pointer *pointer)
}
}
break;
+#ifdef WITH_SEARCH
case ICON_TOOLBAR_SEARCH:
ro_gui_search_open(g, 0, 0, false, true);
break;
+#endif
case ICON_TOOLBAR_SCALE:
current_gui = g;
ro_gui_menu_prepare_scale();
@@ -1351,9 +1353,11 @@ bool ro_gui_window_keypress(struct gui_window *g, int key, bool toolbar)
ro_gui_open_help_page("docs");
return true;
+#ifdef WITH_SEARCH
case wimp_KEY_F4: /* Search */
ro_gui_search_open(g, 0, 0, false, true);
return true;
+#endif
case wimp_KEY_F5: /* Refresh. */
browser_window_reload(g->bw, false);
@@ -1482,9 +1486,11 @@ bool ro_gui_window_keypress(struct gui_window *g, int key, bool toolbar)
}
return true;
+#ifdef WITH_PRINT
case wimp_KEY_PRINT:
ro_gui_print_open(g, 0, 0, false, true);
return true;
+#endif
case wimp_KEY_UP:
case wimp_KEY_DOWN: