[PATCH] [WIP] fdo#45747 - [EasyHack] remove the limitation to 3 sort entries in calc, part 2

Albert Thuswaldner albert.thuswaldner at gmail.com
Mon May 21 14:21:19 PDT 2012


Hi Markus,

Forgot to CC the list in my previous mail, sorry for the noise.
The patch in the last mail was also wrong.

On Fri, May 18, 2012 at 12:10 PM, Markus Mohrhard
<markus.mohrhard at googlemail.com> wrote:
> Hello Albert,
>
> Sorry that it took me a bit to review your patch but my master trees
> are totally screwed for my own feature. I now checked your patch and
> solved the conflicts that were related to my last fix for sort
> dialogs. Attached you'll find a patch that applies cleanly on master.

Thanks.

> I checked the dialog and it looks like we need to move some items a
> bit.

Yea, that's related to different themes/widget set, I guess. It looks
great on my computer running LO under KDE. I had a fixed offset which
dictated the spacing between two sort key items, in the new patch I
now calculate the spacing based on position and height of the widgets.
Still not perfect, needs some wiggling.
It would be great if someone could help out with this :)

> I've attached a simple patch showing how to do this. The patch will
> not compile but shows already the basic ideas. The idea is to move the
> ScSortKeyItems variable into tpsort and only pass a reference. I think
> a good final step is to use a boost::ptr_vector which will control the
> lifetime of the contained objects.

Thanks for the code pointer regarding the reference, It was along the
line what I was thinking. I've now implemented this using
boost::ptr_vector in the new patch. It seems to work, however
strangely enough LO now segfaults on exit of the sort dialog. The
stack trace suggest the problem to be in the Window class, however
boost::ptr_vector should take care of the deletion of its members, so
no dedicated destructor should be necessary. I'm confused...

Could you have a look at this problem. Thanks. I'm feeling the heat of
the feature freeze...

/Albert
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-fdo-45747-remove-the-limitation-to-3-sort-entries-in.patch
Type: text/x-patch
Size: 39608 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20120521/227fee79/attachment-0001.bin>


More information about the LibreOffice mailing list