Kaydet (Commit) d9b03172 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Clean up Sequence construction

...to avoid silly errors like the one fixed with
37039fde "Missing comma."

Change-Id: Iab4d25f44fd8867ee1ef5e15c209ada5c6ebb0c8
Reviewed-on: https://gerrit.libreoffice.org/19871Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarStephan Bergmann <sbergman@redhat.com>
üst ffdc5db2
...@@ -94,72 +94,50 @@ struct NamespaceIds: public rtl::StaticWithInit< ...@@ -94,72 +94,50 @@ struct NamespaceIds: public rtl::StaticWithInit<
{ {
Sequence< beans::Pair< OUString, sal_Int32 > > operator()() Sequence< beans::Pair< OUString, sal_Int32 > > operator()()
{ {
static const char* const namespaceURIs[] = { return css::uno::Sequence<css::beans::Pair<OUString, sal_Int32>>{
"http://www.w3.org/XML/1998/namespace", {"http://www.w3.org/XML/1998/namespace", NMSP_xml},
"http://schemas.openxmlformats.org/package/2006/relationships", {"http://schemas.openxmlformats.org/package/2006/relationships",
"http://schemas.openxmlformats.org/officeDocument/2006/relationships", NMSP_packageRel},
"http://purl.oclc.org/ooxml/officeDocument/relationships", {"http://schemas.openxmlformats.org/officeDocument/2006/relationships",
"http://schemas.openxmlformats.org/drawingml/2006/main", NMSP_officeRel},
"http://purl.oclc.org/ooxml/drawingml/main", {"http://purl.oclc.org/ooxml/officeDocument/relationships",
"http://schemas.openxmlformats.org/drawingml/2006/diagram", NMSP_officeRel},
"http://purl.oclc.org/ooxml/drawingml/diagram", {"http://schemas.openxmlformats.org/drawingml/2006/main", NMSP_dml},
"http://schemas.openxmlformats.org/drawingml/2006/chart", {"http://purl.oclc.org/ooxml/drawingml/main", NMSP_dml},
"http://schemas.openxmlformats.org/drawingml/2006/chartDrawing", {"http://schemas.openxmlformats.org/drawingml/2006/diagram",
"urn:schemas-microsoft-com:vml", NMSP_dmlDiagram},
"urn:schemas-microsoft-com:office:office", {"http://purl.oclc.org/ooxml/drawingml/diagram", NMSP_dmlDiagram},
"urn:schemas-microsoft-com:office:word", {"http://schemas.openxmlformats.org/drawingml/2006/chart",
"urn:schemas-microsoft-com:office:excel", NMSP_dmlChart},
"urn:schemas-microsoft-com:office:powerpoint", {"http://schemas.openxmlformats.org/drawingml/2006/chartDrawing",
"http://schemas.microsoft.com/office/2006/activeX", NMSP_dmlChartDr},
"http://schemas.openxmlformats.org/spreadsheetml/2006/main", {"urn:schemas-microsoft-com:vml", NMSP_vml},
"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing", {"urn:schemas-microsoft-com:office:office", NMSP_vmlOffice},
"http://schemas.microsoft.com/office/excel/2006/main", {"urn:schemas-microsoft-com:office:word", NMSP_vmlWord},
"http://schemas.openxmlformats.org/presentationml/2006/main", {"urn:schemas-microsoft-com:office:excel", NMSP_vmlExcel},
"http://schemas.openxmlformats.org/markup-compatibility/2006", {"urn:schemas-microsoft-com:office:powerpoint", NMSP_vmlPowerpoint},
"http://schemas.openxmlformats.org/spreadsheetml/2006/main/v2", {"http://schemas.microsoft.com/office/2006/activeX", NMSP_ax},
"http://schemas.microsoft.com/office/drawing/2008/diagram", {"http://schemas.openxmlformats.org/spreadsheetml/2006/main",
"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main", NMSP_xls},
"http://schemas.libreoffice.org/", {"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing",
"http://schemas.microsoft.com/office/powerpoint/2010/main", NMSP_xm},
"http://schemas.microsoft.com/office/powerpoint/2012/main" {"http://schemas.microsoft.com/office/excel/2006/main",
}; NMSP_dmlSpreadDr},
{"http://schemas.openxmlformats.org/presentationml/2006/main",
static const sal_Int32 namespaceIds[] = { NMSP_ppt},
NMSP_xml, {"http://schemas.openxmlformats.org/markup-compatibility/2006",
NMSP_packageRel, NMSP_mce},
NMSP_officeRel, {"http://schemas.openxmlformats.org/spreadsheetml/2006/main/v2",
NMSP_officeRel, NMSP_mceTest},
NMSP_dml, {"http://schemas.microsoft.com/office/drawing/2008/diagram",
NMSP_dml, NMSP_dsp},
NMSP_dmlDiagram, {"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main",
NMSP_dmlDiagram, NMSP_xls14Lst},
NMSP_dmlChart, {"http://schemas.libreoffice.org/", NMSP_loext},
NMSP_dmlChartDr, {"http://schemas.microsoft.com/office/powerpoint/2010/main",
NMSP_vml, NMSP_p14},
NMSP_vmlOffice, {"http://schemas.microsoft.com/office/powerpoint/2012/main",
NMSP_vmlWord, NMSP_p15}};
NMSP_vmlExcel,
NMSP_vmlPowerpoint,
NMSP_ax,
NMSP_xls,
NMSP_xm,
NMSP_dmlSpreadDr,
NMSP_ppt,
NMSP_mce,
NMSP_mceTest,
NMSP_dsp,
NMSP_xls14Lst,
NMSP_loext,
NMSP_p14,
NMSP_p15,
};
Sequence< beans::Pair< OUString, sal_Int32 > > aRet(SAL_N_ELEMENTS(namespaceIds));
for( sal_Int32 i=0; i<aRet.getLength(); ++i )
aRet[i] = make_Pair(
OUString::createFromAscii(namespaceURIs[i]),
namespaceIds[i]);
return aRet;
} }
}; };
......
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