summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFran├žois Revol <revol@free.fr>2014-01-16 17:27:31 +0100
committerFran├žois Revol <revol@free.fr>2014-01-16 17:28:16 +0100
commit90742e6b4bb39b8821c08c95022fcdbee9e81557 (patch)
tree5aabef13edd22c48620d4f77a22deff2cc7235d0
parent7c71ad4f5a0fe6d4bce4eb9f65ececed36de2014 (diff)
downloadnetsurf-90742e6b4bb39b8821c08c95022fcdbee9e81557.tar.gz
netsurf-90742e6b4bb39b8821c08c95022fcdbee9e81557.tar.bz2
beos: Fix build
gcc2 doesn't know about named initializers in C++...
-rw-r--r--beos/download.cpp8
-rw-r--r--beos/download.h2
-rw-r--r--beos/font.cpp1
-rw-r--r--beos/gui.cpp39
-rw-r--r--beos/gui_options.cpp1
-rw-r--r--beos/window.cpp46
6 files changed, 54 insertions, 43 deletions
diff --git a/beos/download.cpp b/beos/download.cpp
index 2e259bccf..8a55e9de1 100644
--- a/beos/download.cpp
+++ b/beos/download.cpp
@@ -249,10 +249,10 @@ static void gui_download_window_done(struct gui_download_window *dw)
}
static struct gui_download_table download_table = {
- .create = gui_download_window_create,
- .data = gui_download_window_data,
- .error = gui_download_window_error,
- .done = gui_download_window_done,
+ gui_download_window_create,
+ gui_download_window_data,
+ gui_download_window_error,
+ gui_download_window_done,
};
struct gui_download_table *beos_download_table = &download_table;
diff --git a/beos/download.h b/beos/download.h
index 245ee8641..0ce387efc 100644
--- a/beos/download.h
+++ b/beos/download.h
@@ -16,4 +16,4 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-struct gui_download_table *beos_download_table;
+extern struct gui_download_table *beos_download_table;
diff --git a/beos/font.cpp b/beos/font.cpp
index 5636743f5..b262562d3 100644
--- a/beos/font.cpp
+++ b/beos/font.cpp
@@ -36,6 +36,7 @@ extern "C" {
#include "utils/utils.h"
#include "utils/log.h"
#include "utils/nsoption.h"
+#include "utils/nsurl.h"
}
#include "beos/gui.h"
diff --git a/beos/gui.cpp b/beos/gui.cpp
index 4a6475894..9e730a0c8 100644
--- a/beos/gui.cpp
+++ b/beos/gui.cpp
@@ -70,7 +70,7 @@ extern "C" {
#include "beos/window.h"
#include "beos/throbber.h"
#include "beos/filetype.h"
-//#include "beos/download.h"
+#include "beos/download.h"
#include "beos/schedule.h"
#include "beos/fetch_rsrc.h"
#include "beos/scaffolding.h"
@@ -1059,18 +1059,21 @@ static bool path_add_part(char *path, int length, const char *newpart)
}
static struct gui_clipboard_table beos_clipboard_table = {
- .get = gui_get_clipboard,
- .set = gui_set_clipboard,
+ gui_get_clipboard,
+ gui_set_clipboard,
};
static struct gui_browser_table beos_browser_table = {
- .poll = gui_poll,
- .quit = gui_quit,
- .get_resource_url = gui_get_resource_url,
- .launch_url = gui_launch_url,
- .filename_from_path = filename_from_path,
- .path_add_part = path_add_part,
- .login = gui_401login_open,
+ gui_poll,
+ filename_from_path,
+ path_add_part,
+ gui_quit,
+ NULL, //set_search_ico
+ gui_get_resource_url,
+ gui_launch_url,
+ NULL, //create_form_select_menu
+ NULL, //cert_verify
+ gui_401login_open
};
@@ -1080,10 +1083,10 @@ int main(int argc, char** argv)
nserror ret;
BPath options;
struct gui_table beos_gui_table = {
- .browser = &beos_browser_table,
- .window = beos_window_table,
- .clipboard = &beos_clipboard_table,
- .download = beos_download_table,
+ &beos_browser_table,
+ beos_window_table,
+ beos_download_table,
+ &beos_clipboard_table
};
if (find_directory(B_USER_SETTINGS_DIRECTORY, &options, true) == B_OK) {
@@ -1131,10 +1134,10 @@ int gui_init_replicant(int argc, char** argv)
nserror ret;
BPath options;
struct gui_table beos_gui_table = {
- .browser = &beos_browser_table,
- .window = beos_window_table,
- .clipboard = &beos_clipboard_table,
- .download = beos_download_table,
+ &beos_browser_table,
+ beos_window_table,
+ beos_download_table,
+ &beos_clipboard_table
};
if (find_directory(B_USER_SETTINGS_DIRECTORY, &options, true) == B_OK) {
diff --git a/beos/gui_options.cpp b/beos/gui_options.cpp
index 2c56cf710..035c62941 100644
--- a/beos/gui_options.cpp
+++ b/beos/gui_options.cpp
@@ -24,6 +24,7 @@
extern "C" {
#include "utils/log.h"
#include "utils/nsoption.h"
+#include "utils/nsurl.h"
}
#include "beos/gui.h"
#include "beos/scaffolding.h"
diff --git a/beos/window.cpp b/beos/window.cpp
index fc46eba96..5863c06ae 100644
--- a/beos/window.cpp
+++ b/beos/window.cpp
@@ -1348,28 +1348,34 @@ static void gui_window_get_dimensions(struct gui_window *g, int *width, int *hei
}
static struct gui_window_table window_table = {
- .create = gui_window_create,
- .destroy = gui_window_destroy,
- .redraw = gui_window_redraw_window,
- .update = gui_window_update_box,
- .get_scroll = gui_window_get_scroll,
- .set_scroll = gui_window_set_scroll,
- .get_dimensions = gui_window_get_dimensions,
- .update_extent = gui_window_update_extent,
-
- .new_content = gui_window_new_content,
- .set_pointer = gui_window_set_pointer,
- .place_caret = gui_window_place_caret,
- .remove_caret = gui_window_remove_caret,
- .start_selection = gui_start_selection,
+ gui_window_create,
+ gui_window_destroy,
+ gui_window_redraw_window,
+ gui_window_update_box,
+ gui_window_get_scroll,
+ gui_window_set_scroll,
+ gui_window_get_dimensions,
+ gui_window_update_extent,
/* from scaffold */
- .set_icon = gui_window_set_icon,
- .set_title = gui_window_set_title,
- .set_url = gui_window_set_url,
- .set_status = gui_window_set_status,
- .start_throbber = gui_window_start_throbber,
- .stop_throbber = gui_window_stop_throbber,
+ gui_window_set_title,
+ gui_window_set_url,
+ gui_window_set_icon,
+ gui_window_set_status,
+ gui_window_set_pointer,
+ gui_window_place_caret,
+ gui_window_remove_caret,
+ gui_window_start_throbber,
+ gui_window_stop_throbber,
+ NULL, //drag_start
+ NULL, //save_link
+ NULL, //scroll_visible
+ NULL, //scroll_start
+ gui_window_new_content,
+ NULL, //file_gadget_open
+ NULL, //drag_save_object
+ NULL, //drag_save_selection
+ gui_start_selection
};
struct gui_window_table *beos_window_table = &window_table;