Commit ce12ef5e authored by Chyla Zbigniew's avatar Chyla Zbigniew

(workbook_persist_file_load): Use wb_view_open instead of


(workbook_persist_file_load): Use wb_view_open instead of
workbook_load_from.
(workbook_persist_file_save): Use wb_view_save_as instead of calling
gnumeric_xml_write_workbook directly.

Of course it's still broken as it was before :(
parent 2d4e75c9
......@@ -31,6 +31,10 @@
set file_saver to NULL in signal handler. Disconnect when changing file
saver or destroying the workbook.
(workbook_get_file_saver): New accessor function.
(workbook_persist_file_load): Use wb_view_open instead of
workbook_load_from.
(workbook_persist_file_save): Use wb_view_save_as instead of calling
gnumeric_xml_write_workbook directly.
* src/workbook-view.[ch]
(wb_view_set_attributev): Renamed to wb_view_set_attribute_list and
......
......@@ -31,6 +31,10 @@
set file_saver to NULL in signal handler. Disconnect when changing file
saver or destroying the workbook.
(workbook_get_file_saver): New accessor function.
(workbook_persist_file_load): Use wb_view_open instead of
workbook_load_from.
(workbook_persist_file_save): Use wb_view_save_as instead of calling
gnumeric_xml_write_workbook directly.
* src/workbook-view.[ch]
(wb_view_set_attributev): Renamed to wb_view_set_attribute_list and
......
......@@ -31,6 +31,10 @@
set file_saver to NULL in signal handler. Disconnect when changing file
saver or destroying the workbook.
(workbook_get_file_saver): New accessor function.
(workbook_persist_file_load): Use wb_view_open instead of
workbook_load_from.
(workbook_persist_file_save): Use wb_view_save_as instead of calling
gnumeric_xml_write_workbook directly.
* src/workbook-view.[ch]
(wb_view_set_attributev): Renamed to wb_view_set_attribute_list and
......
......@@ -31,6 +31,10 @@
set file_saver to NULL in signal handler. Disconnect when changing file
saver or destroying the workbook.
(workbook_get_file_saver): New accessor function.
(workbook_persist_file_load): Use wb_view_open instead of
workbook_load_from.
(workbook_persist_file_save): Use wb_view_save_as instead of calling
gnumeric_xml_write_workbook directly.
* src/workbook-view.[ch]
(wb_view_set_attributev): Renamed to wb_view_set_attribute_list and
......
......@@ -31,6 +31,10 @@
set file_saver to NULL in signal handler. Disconnect when changing file
saver or destroying the workbook.
(workbook_get_file_saver): New accessor function.
(workbook_persist_file_load): Use wb_view_open instead of
workbook_load_from.
(workbook_persist_file_save): Use wb_view_save_as instead of calling
gnumeric_xml_write_workbook directly.
* src/workbook-view.[ch]
(wb_view_set_attributev): Renamed to wb_view_set_attribute_list and
......
......@@ -312,22 +312,20 @@ static int
workbook_persist_file_load (BonoboPersistFile *ps, const CORBA_char *filename,
CORBA_Environment *ev, void *closure)
{
/* FIXME (I'll fix this today - zbigniew)
WorkbookView *wbv = closure;
return workbook_load_from (NULL, wbv, filename); */
return -1;
return wb_view_open (wbv, /* FIXME */ NULL, filename) ? 0 : -1;
}
static int
workbook_persist_file_save (BonoboPersistFile *ps, const CORBA_char *filename,
CORBA_Environment *ev, void *closure)
{
/* FIXME (I'll fix this today - zbigniew)
WorkbookView *wbv = closure;
GnumFileSaver *fs;
return gnumeric_xml_write_workbook (NULL, NULL, wbv, filename); */
return -1;
fs = get_file_saver_by_id ("Gnumeric_XmlIO:gnum_xml");
return wb_view_save_as (wbv, /* FIXME */ NULL, fs, filename) ? 0 : -1;
}
extern Bonobo_Unknown
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment