Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


On Sun, 2011-08-21 at 20:41 +0200, Arnaud Versini wrote:
Hi,

New version of the patch. I have added a method :
IDocumentStatistic::GetUpdatedDocStat wich check state before
returning. I left some UpdateDocStat but I will continue it later.

Looks basically good to me. We can distinguish between the two purposes
of the old call, to get updated stats because something wants to use
them, and to force updating of cached statistics for e.g. updating
fields.

I paused for a bit seeing as I got a bit confused, and wrote a
regression test for SwDocStat e.g. sw/qa/core/swdoc-test.cxx
SwDocTest::testDocStat

So, pushed now. I took the liberty of adding a GetUpdatedDocStat to
EditShell as well and making those additional changes.

There's probably no good reason to want possibly out-dated stats is
there ?, so...

a) We/you should remove any remaining GetDocStat calls and replace them
with the GetUpdatedDocStat when they want to get current stats or
UpdateDocStat when they might want to update the internal stats only

b) Remove GetDocStat entirely and remove it from the new regression test
too

c) remove that bModified member from SwDocStat and move it into SwDoc as
m_bStaleStats or something

d) I'm not sure there's any good reason to set the DocStat in the
(current) rtf filter.

C.


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.