[gnumeric] ODS: Don't refer to gsf_ooo_ns variable.
- From: Morten Welinder <mortenw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnumeric] ODS: Don't refer to gsf_ooo_ns variable.
- Date: Wed, 21 Mar 2012 00:25:26 +0000 (UTC)
commit 73ffb2e174c2561a417824eec071881ba9b0a89e
Author: Morten Welinder <terra gnome org>
Date: Tue Mar 20 20:23:54 2012 -0400
ODS: Don't refer to gsf_ooo_ns variable.
We're outside C with its defintion, so use the function instead.
plugins/openoffice/ChangeLog | 3 +++
plugins/openoffice/openoffice-read.c | 17 ++++++++++-------
2 files changed, 13 insertions(+), 7 deletions(-)
---
diff --git a/plugins/openoffice/ChangeLog b/plugins/openoffice/ChangeLog
index a110d61..6147da2 100644
--- a/plugins/openoffice/ChangeLog
+++ b/plugins/openoffice/ChangeLog
@@ -1,5 +1,8 @@
2012-03-20 Morten Welinder <terra gnome org>
+ * openoffice-read.c (openoffice_file_open): Don't refer to
+ gsf_ooo_ns variable.
+
* openoffice-write.c (openoffice_file_save_real): Store odf
version in state. Else store version elsewhere.
(odf_write_xl_style): Supply new odf version argument to
diff --git a/plugins/openoffice/openoffice-read.c b/plugins/openoffice/openoffice-read.c
index ebc1985..5e29103 100644
--- a/plugins/openoffice/openoffice-read.c
+++ b/plugins/openoffice/openoffice-read.c
@@ -7064,7 +7064,8 @@ od_draw_object (GsfXMLIn *xin, xmlChar const **attrs)
content = gsf_infile_child_by_vname (state->zip, name, "styles.xml", NULL);
if (content != NULL) {
GsfXMLInDoc *doc =
- gsf_xml_in_doc_new (get_styles_dtd (), gsf_ooo_ns);
+ gsf_xml_in_doc_new (get_styles_dtd (),
+ get_gsf_ooo_ns ());
odf_clear_conventions (state); /* contain references to xin */
gsf_xml_in_doc_parse (doc, content, state);
gsf_xml_in_doc_free (doc);
@@ -7075,7 +7076,7 @@ od_draw_object (GsfXMLIn *xin, xmlChar const **attrs)
content = gsf_infile_child_by_vname (state->zip, name, "content.xml", NULL);
if (content != NULL) {
GsfXMLInDoc *doc =
- gsf_xml_in_doc_new (get_dtd (), gsf_ooo_ns);
+ gsf_xml_in_doc_new (get_dtd (), get_gsf_ooo_ns ());
odf_clear_conventions (state); /* contain references to xin */
gsf_xml_in_doc_parse (doc, content, state);
gsf_xml_in_doc_free (doc);
@@ -10891,16 +10892,18 @@ openoffice_file_open (G_GNUC_UNUSED GOFileOpener const *fo, GOIOContext *io_cont
}
if (NULL != styles) {
- GsfXMLInDoc *doc = gsf_xml_in_doc_new (styles_dtd, gsf_ooo_ns);
+ GsfXMLInDoc *doc = gsf_xml_in_doc_new (styles_dtd,
+ get_gsf_ooo_ns ());
gsf_xml_in_doc_parse (doc, styles, &state);
gsf_xml_in_doc_free (doc);
odf_clear_conventions (&state); /* contain references to xin */
g_object_unref (styles);
}
- doc = gsf_xml_in_doc_new (
- (state.ver == OOO_VER_1) ? ooo1_content_dtd : opendoc_content_dtd,
- gsf_ooo_ns);
+ doc = gsf_xml_in_doc_new ((state.ver == OOO_VER_1)
+ ? ooo1_content_dtd
+ : opendoc_content_dtd,
+ get_gsf_ooo_ns ());
if (gsf_xml_in_doc_parse (doc, contents, &state)) {
GsfInput *settings;
char const *filesaver;
@@ -10939,7 +10942,7 @@ openoffice_file_open (G_GNUC_UNUSED GOFileOpener const *fo, GOIOContext *io_cont
settings = gsf_infile_child_by_name (zip, "settings.xml");
if (settings != NULL) {
GsfXMLInDoc *sdoc = gsf_xml_in_doc_new
- (opendoc_settings_dtd, gsf_ooo_ns);
+ (opendoc_settings_dtd, get_gsf_ooo_ns ());
gsf_xml_in_doc_parse (sdoc, settings, &state);
gsf_xml_in_doc_free (sdoc);
odf_clear_conventions (&state); /* contain references to xin */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]