summaryrefslogtreecommitdiff
path: root/riscos/gui.c
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2015-06-19 16:29:42 +0100
committerVincent Sanders <vince@kyllikki.org>2015-06-21 23:27:22 +0100
commit67ded2a02a4f3f4d2a0ab156f3343dc93f4ba04c (patch)
tree3110af1e6d0bea57725b74db6efeb3a821628890 /riscos/gui.c
parent335bbe4f52b9fdb74e377b83906eaab4456666cf (diff)
downloadnetsurf-67ded2a02a4f3f4d2a0ab156f3343dc93f4ba04c.tar.gz
netsurf-67ded2a02a4f3f4d2a0ab156f3343dc93f4ba04c.tar.bz2
This moves message loading out of netsurf_init into each frontend
The translated message loading is dependant on configuration of resource location in each frontend, additionally they should have the ability to deal with errors in this loading in a implementation specific manner. This also extends the message loading API to be capable of loading from an inline memory buffer instead of from a file.
Diffstat (limited to 'riscos/gui.c')
-rw-r--r--riscos/gui.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/riscos/gui.c b/riscos/gui.c
index 3a47d088b..2dd94337c 100644
--- a/riscos/gui.c
+++ b/riscos/gui.c
@@ -2481,11 +2481,14 @@ int main(int argc, char** argv)
die("Failed to locate Messages resource.");
}
+ /* initialise messages */
+ messages_add_from_file(path);
+
/* obtain cache path */
cachepath = get_cachepath();
/* common initialisation */
- ret = netsurf_init(path, cachepath);
+ ret = netsurf_init(cachepath);
free(cachepath);
if (ret != NSERROR_OK) {
die("NetSurf failed to initialise core");
@@ -2496,7 +2499,7 @@ int main(int argc, char** argv)
sprite_init();
/* Load some extra RISC OS specific Messages */
- messages_load("NetSurf:Resources.LangNames");
+ messages_add_from_file("NetSurf:Resources.LangNames");
ret = gui_init(argc, argv);
if (ret != NSERROR_OK) {