From 9644d0594c1dfcc6e104754793a75d23c7a6840e Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Fri, 10 May 2013 11:54:26 +0100 Subject: Remove struct selection from gui_drag_save_selection, so gui.h doesn't need it now. --- riscos/save.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'riscos/save.c') diff --git a/riscos/save.c b/riscos/save.c index 549a2ab3e..47006d287 100644 --- a/riscos/save.c +++ b/riscos/save.c @@ -395,7 +395,7 @@ void gui_drag_save_object(gui_save_type save_type, hlcache_handle *c, * \param g gui window */ -void gui_drag_save_selection(struct selection *s, struct gui_window *g) +void gui_drag_save_selection(struct gui_window *g, const char *selection) { wimp_pointer pointer; char icon_buf[20]; @@ -421,7 +421,10 @@ void gui_drag_save_selection(struct selection *s, struct gui_window *g) if (gui_save_selection == NULL) free(gui_save_selection); - gui_save_selection = selection_get_copy(s); + if (selection == NULL) + gui_save_selection = strdup(""); + else + gui_save_selection = strdup(selection); ro_gui_save_set_state(NULL, GUI_SAVE_TEXT_SELECTION, NULL, save_leafname, LEAFNAME_MAX, -- cgit v1.2.3