help needed (embedded writed docs): fdo#44081 fix circular dependency sw / sfx

Lionel Elie Mamane lionel at mamane.lu
Thu Aug 28 07:51:52 PDT 2014


On Wed, Aug 27, 2014 at 09:27:45PM +0200, Tomaž Vajngerl wrote:
> On Wed, Aug 27, 2014 at 7:44 PM, Lionel Elie Mamane <lionel at mamane.lu> wrote:

>> I'd like to have some help on fdo#44081
>> https://bugs.freedesktop.org/44081

>> So I worked on that, and wrote https://gerrit.libreoffice.org/11152
>> Which I'm deeply unhappy about:

>> 1) It makes sfx2 use private headers from sw, in a way that does not
>>    seem immediately trivial to fix; I mean these headers use other
>>    private headers, so we'd have to move more headers to public
>>    (include/sw). Doable, but maybe overkill.

>> 2) Worse, it includes a circular dependency between libswlo and
>>    libsfxlo. IMHO, we cannot have that.

> Add a (virtual) method to SfxObjectShell with a default implementation
> and override the implementation in SwDocShell (SwDocShell derives from
> SfxObjectShell).

I discovered:

 1) SwDocShell->GetView() returns SwView, a subclass of SfxViewShell

 2) SfxObjectShell has a GetViewShell() that looks like it should
    return the same result as SwDocShell->GetView()

So I arranged for the above to happen. Any sw dev has anything
negative to say about this?

 3) I added virtual GetFormShell() to SfxViewShell, which SwView
    overrides.

If nobody screams "soon", I'm going to push this to master.


Thanks for your encouragements, Tomaž.

-- 
Lionel


More information about the LibreOffice mailing list