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


On Thu, 2012-05-10 at 17:37 +0100, Michael Meeks wrote:
      Surely that should read:

              nBgn = m_aPageCache[nRel];

      or did I go a bit crazy ? [ I'm trying to turn the above into that
mentally and giving up ;-].

how about a 4 element chain of 10 11 12 13

with a scenario of nBgn = 11, nRel = 2, desired result is 13

so nBgn of 11 gives a nBgnDistance of 1
so desired nIndex is 3, nBgnDistance (1) + nRel (2);

so nBgn = m_aPagesCache[nIndex]; and set nRel to 0 to indicate
successfully stepped to desired page

with an alternative scenario of nBgn = 11, nRel = 8
get nBgnDistance of 1 again, so desired nIndex of 9, clip it as its out
of scale to the max of 3, reduce nRel by how valid steps we took (2) to
give 6 un-achievable steps.... oops my out-of-bounds code is all
wrong :-) fixed with 75e7643e22bcf674739ca890bfc06f80e872624b

      StgFATStrm::SetPage(); should prolly just update that vector as well as
doing the nasty fat walk so:

      m_aPageCache[nBlocks] = nNewPage;

would have to check around the insertion point if the sort order is
still valid afterwards I guess, throwing away everything is my current
cowardly conservative approach on any modifications

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.