On Tuesday 24 of January 2012, Michael Stahl wrote: > On 23/01/12 21:31, Lubos Lunak wrote: > > Technically, I get in SwXDocumentSettings::_setSingleValue() first a > > call with HANDLE_CURRENT_DATABASE_DATA_SOURCE and then with > > HANDLE_CURRENT_DATABASE_COMMAND. They both call first SwDoc::GetDBDesc(), > > which first applies the command to some default data source and > > afterwards sets the given data source without the right command > > afterwards. The reversed ordering of the input data comes from some call > > far far in the past and I have no idea if reusing old command does not > > cause a problem for other code using this functionality. > > i wonder, does it start doing something immediately if you set a single > property? if nothing is actually done until later, probably we could > risk to change the setProperty so a new DATA_SOURCE doesn't clear a > previously set COMMAND; but note that i have no idea what this stuff > does anyway...
Count me in. > > It seems to be quite a common way for LO code to use this > > let's-push-all-the-data-as-properties-one-by-one approach, so I wonder > > what the common way of avoiding this problem is? Preferably something > > that's not an ugly hack, excuse the naivety. > > i'm not aware of a general solution for this problem; i'm afraid if > there are good reasons not do a change as above, then ugly hack is in > order... i don't remember running into such a problem before, probably > this kind of dependency is quite rare. I've eventually settled on db0f839920c38973f8448df0f74de7c4c95c832c , could somebody review and push to 3.5? -- Lubos Lunak l.lu...@suse.cz _______________________________________________ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice