diff options
author | Michael Stahl <mstahl@redhat.com> | 2013-12-05 12:15:15 +0100 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2013-12-05 13:00:27 +0100 |
commit | c5138cad87575283cdf0670355f2b2cddae93fc8 (patch) | |
tree | 2cd071d5cf900636b87bd6ee47f1351fa4f18e8d /include | |
parent | de45a49273542c9046e0cfc2b75c863573eb6c38 (diff) |
fdo#68724: sw: fix crash on Insert->File with Hybrid PDF
This is an unfortunate combination of 2 special cases:
- the Hybrid PDF has its own XFilter implementation to extract the
embedded ODF document
- Writer needs to create a SwReader with SwPaM for Insert
Since the PDF XFilter uses a special service in sfx2 to implement
the import, handling this requires a new method in SfxObjectShell
that calls back into Writer to create the properly setup SwReader.
Change-Id: Ie85f3bfa322bfe883c479e1cb198a8bf0cbbac23
Diffstat (limited to 'include')
-rw-r--r-- | include/sfx2/objsh.hxx | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/include/sfx2/objsh.hxx b/include/sfx2/objsh.hxx index fac2625698cd..de041fbf3bc7 100644 --- a/include/sfx2/objsh.hxx +++ b/include/sfx2/objsh.hxx @@ -116,6 +116,9 @@ namespace com { namespace sun { namespace star { namespace lang { class XComponent; } + namespace text { + class XTextRange; + } } } } typedef sal_uInt32 SfxObjectShellFlags; @@ -348,7 +351,12 @@ public: sal_Bool bForceNonModified = sal_False ); sal_Bool SaveCompletedChildren( sal_Bool bSuccess ); - virtual sal_Bool ImportFrom( SfxMedium &rMedium, bool bInsert ); + /** a very special case to insert at a position in Writer from UNO, + via OwnSubFilterService */ + virtual bool InsertGeneratedStream(SfxMedium& rMedium, + css::uno::Reference<css::text::XTextRange> const& xInsertPosition); + virtual bool ImportFrom( SfxMedium &rMedium, + css::uno::Reference<css::text::XTextRange> const& xInsertPosition); sal_Bool ExportTo( SfxMedium &rMedium ); // xmlsec05, check with SFX team |