summaryrefslogtreecommitdiff
path: root/dbaccess/source/core
AgeCommit message (Collapse)Author
2023-11-09default to ignoring libreoffice special-purpose protocols in calc hyperlinkCaolán McNamara
Change-Id: Ib9f62be3acc05f24ca234dec0fec21e24579e9de Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158911 Tested-by: Jenkins Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2023-11-07Pass XInteractionHandler to hasTrustedScriptingSignature instead of a boolMike Kaganski
This allows to use the same interaction handler there, as used in DocumentMacroMode::adjustMacroMode. hasTrustedScriptingSignature used to find its own interaction handler; and that would conflict with e.g. ODatabaseModelImpl::adjustMacroMode_AutoReject, which passes nullptr to adjustMacroMode, with intention to not show any UI; but with signed macros (see tdf#97694), the UI would still appear. Change-Id: Ia209f96bef67dccfe1da23c4d172ac47497f8eb1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/159070 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-10-23Extended loplugin:ostr: Rewrite some O[U]StringLiteral -> O[U]StringStephan Bergmann
...in include files. This is a mix of automatic rewriting in include files and manual fixups (mostly addressing loplugin:redundantfcast) in source files that include those. Change-Id: I1f3cc1e67b9cabd2e9d61a4d9e9a01e587ea35cc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158337 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2023-10-20dbaccess/source/core/inc/object.hxx unused since initial importJulien Nabet
Change-Id: Iad9c4f234833ce4c605040b9d0f9b86150791c99 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158210 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2023-10-19Extended loplugin:ostr: Automatic rewrite O[U]StringLiteral: dbaccessStephan Bergmann
Change-Id: I5f92e390ef57ae8f2aba43782c11ca5ee31dba93 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158187 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2023-10-19Related tdf#144256: missing removePropertyChangeListener calls in AppControllerJulien Nabet
Compare and use same order as in dbaccess/source/core/dataaccess/datasource.cxx Change-Id: Id025e6e801387c2c377af88d2816c68ed9183e55 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158171 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2023-10-19Related tdf#144256: remove m_pSharedConnectionManagerJulien Nabet
to only use "m_xSharedConnectionManager". For this, it required some refactoring but except the removing, logic hasn't been changed. Change-Id: Iccfe5c45381f31019a0751a61cea6661c88188f1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158107 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-10-18Drop duplicated forward declarationsMike Kaganski
Change-Id: I0804518ce97e3f5f8098c4a4416675409746aaea Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158044 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-10-18Replace useless typedef OSharedConnection_BASE2 and replace it by its valueJulien Nabet
Change-Id: I660813058077a36bcf80a3128b53767c851c2672 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158105 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2023-10-18Related tdf#144256: fix order of disposing in OSharedConnectionJulien Nabet
In dbaccess/source/core/dataaccess/SharedConnection.hxx, we got: 35 typedef ::cppu::WeakComponentImplHelper< css::sdbc::XConnection 36 > OSharedConnection_BASE; 37 typedef ::connectivity::OConnectionWrapper OSharedConnection_BASE2; 38 39 class OSharedConnection : public ::cppu::BaseMutex 40 , public OSharedConnection_BASE 41 , public OSharedConnection_BASE2 so first OSharedConnection_BASE ctr is called before OConnectionWrapper ctr therefore OConnectionWrapper dtr should be called before OSharedConnection_BASE dtr It doesn't fix the bug but investigating in all this mess, I'd like to fix these things since it may help. Change-Id: I47255357b4ca02261f31ebf500f3f1ff55642e69 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/158096 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2023-10-14Use exception ctors, instead of setting members laterMike Kaganski
Avoids overwriting source location in message Change-Id: Ia0290c7dd1ab3ea1357712a27ecab75c7b583dd4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157893 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-09-13loplugin:unodispose in dbaccessNoel Grandin
Change-Id: I7a28204ababc9fec4e90ccbd2f0a485d6bc8d560 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156849 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-09-08no need to use XAggregation for DatabaseRegistrationsNoel Grandin
the delegating class already implements the interface and forwards the method calls Change-Id: I8b0c74be87656675a887ddda2e7c44b63f165c2f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156699 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-09-01connectivity: add neutral context parserHenry Castro
Signed-off-by: Henry Castro <hcastro@collabora.com> Change-Id: I12b0fe811d141873aaa64af5b6c457051c3356b0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156297 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156424 Tested-by: Jenkins
2023-08-28new loplugin:optionalboolNoel Grandin
which warns against using the 'operator bool' conversion of std::optional<bool> which can lead to interesting bugs The bugs that this plugin have been submitted independantly, so this change is just using has_value() in relevant places. Change-Id: I259b837feeecddcb8cd1d7e5db1e85bf505907cb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155978 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-08-08simplify ODatabaseDocument inheritanceNoel Grandin
no need to use two different ImplHelpers here Change-Id: I1c871f8e0e49ff8a0a540e8051f3a89a54130322 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155457 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-07-28tdf#156471: New database wizard - add generic support for embedded databases ↵Pierre
of unknown type e.g. provided by extension or future code. The core assumption is that an embedded database doesn't need a user-configured "connection URL" configured so don't ask for one. Change-Id: I7d11cc0b492782634dd49f74d9d709dca434e990 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154989 Reviewed-by: Lionel Mamane <lionel@mamane.lu> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2023-07-23No need to create an identical obj if we return the same property valuesJulien Nabet
Change-Id: Ib932de42ffec6d71b31a25d53f46f18a26b0b2b0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154762 Reviewed-by: Lionel Mamane <lionel@mamane.lu> Tested-by: Jenkins
2023-06-26new loplugin:constexprliteralNoel Grandin
OUStringLiteral should be declared constexpr, to enforce that it is initialised at compile-time and not runtime. This seems to make a different at least on Visual Studio Change-Id: I1698f5fa22ddb480347c2f4d444530c2e0e88d92 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153499 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-05-31do not throw DisposedException when inside a dispose() methodNoel Grandin
There is no need to do this, as the documentation of css.lang.XComponent::dispose at udkapi/com/sun/star/lang/XComponent.idl states: After this method has been called, the object should behave as passive as possible, thus it should ignore all calls Otherwise, the effect of throwing here is mostly to disturb the flow of logic in caller code, preventing other parts of teardown from proceeding smoothly. Change-Id: I30e6d1b35f85b727debf4405a995fdc0a4fccde6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152450 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-05-28Typo: aCatlog->aCatalogJulien Nabet
Change-Id: I875e94e47d44101a840b711de174f38ad4b85b4e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152357 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2023-05-25Revert "BaseMutex->std::mutex in OPropertyForward"Julien Nabet
This reverts commit b0244ef9e44c5c1dc9faf9705f2ae1dba499d62c. Lock when trying to save a change in a table: #0 futex_wait (private=0, expected=2, futex_word=0x55f20be59550) at ../sysdeps/nptl/futex-internal.h:146 #1 __GI___lll_lock_wait (futex=futex@entry=0x55f20be59550, private=0) at ./nptl/lowlevellock.c:49 #2 0x00007f462caab262 in lll_mutex_lock_optimized (mutex=0x55f20be59550) at ./nptl/pthread_mutex_lock.c:48 #3 ___pthread_mutex_lock (mutex=0x55f20be59550) at ./nptl/pthread_mutex_lock.c:93 #4 0x00007f45fad12a63 in __gthread_mutex_lock(pthread_mutex_t*) (__mutex=0x55f20be59550) at /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/x86_64-linux-gnu/c++/12/bits/gthr-default.h:749 #5 0x00007f45fad138c5 in std::mutex::lock() (this=0x55f20be59550) at /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/std_mutex.h:100 #6 0x00007f45fad1389c in std::unique_lock<std::mutex>::lock() (this=0x7ffd5b691a78) at /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/unique_lock.h:139 #7 0x00007f45fad136b1 in std::unique_lock<std::mutex>::unique_lock(std::mutex&) (this=0x7ffd5b691a78, __m=...) at /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/unique_lock.h:69 #8 0x00007f45fb060b55 in dbaccess::OPropertyForward::setDefinition(com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet> const&) (this=0x55f20be59520, _xDest=uno::Reference to (dbaccess::OTableColumnDescriptor *) 0x55f20bd765b8) at /home/julien/lo/libreoffice/dbaccess/source/core/misc/PropertyForward.cxx:128 #9 0x00007f45fb039edc in dbaccess::OContainerMediator::elementInserted(com::sun::star::container::ContainerEvent const&) (this=0x55f20bd9ac30, _rEvent=...) at /home/julien/lo/libreoffice/dbaccess/source/core/misc/ContainerMediator.cxx:105 #10 0x00007f461ebaa03e in comphelper::OInterfaceContainerHelper3<com::sun::star::container::XContainerListener>::NotifySingleListener<com::sun::star::container::ContainerEvent>::operator()(com::sun::star::uno::Reference<com::sun::star::container::XContainerListener> const&) const (this=0x7ffd5b691c90, listener=uno::Reference to (dbaccess::OContainerMediator *) 0x55f20bd9ac58) at include/comphelper/interfacecontainer3.hxx:252 #11 0x00007f461eba9e4c in comphelper::OInterfaceContainerHelper3<com::sun::star::container::XContainerListener>::forEach<comphelper::OInterfaceContainerHelper3<com::sun::star::container::XContainerListener>::NotifySingleListener<com::sun::star::container::ContainerEvent> >(comphelper::OInterfaceContainerHelper3<com::sun::star::container::XContainerListener>::NotifySingleListener<com::sun::star::container::ContainerEvent> const&) (this=0x55f20ba55ee0, func=...) at include/comphelper/interfacecontainer3.hxx:274 #12 0x00007f461eb8aab3 in comphelper::OInterfaceContainerHelper3<com::sun::star::container::XContainerListener>::notifyEach<com::sun::star::container::ContainerEvent>(void (com::sun::star::container::XContainerListener::*)(com::sun::star::container::ContainerEvent const&), com::sun::star::container::ContainerEvent const&) (this=0x55f20ba55ee0, NotificationMethod=&virtual table offset 32, Event=...) at include/comphelper/interfacecontainer3.hxx:289 #13 0x00007f461eb8527d in connectivity::sdbcx::OCollection::appendByDescriptor(com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet> const&) (this=0x55f20ba55e80, descriptor=uno::Reference to (dbaccess::OTableColumnDescriptor *) 0x55f20b909188) at /home/julien/lo/libreoffice/connectivity/source/sdbcx/VCollection.cxx:388 #14 0x00007f45fb060571 in dbaccess::OPropertyForward::propertyChange(com::sun::star::beans::PropertyChangeEvent const&) (this=0x55f20be59520, evt=...) at /home/julien/lo/libreoffice/dbaccess/source/core/misc/PropertyForward.cxx:94 #15 0x00007f462b59ac96 in cppu::OPropertySetHelper::fire(int*, com::sun::star::uno::Any const*, com::sun::star::uno::Any const*, int, unsigned char) (this=0x55f20b7e8098, pnHandles=0x7ffd5b69320c, pNewValues=0x7ffd5b6934a8, pOldValues=0x7ffd5b693198, nHandles=1, bVetoable=0 '\000') at /home/julien/lo/libreoffice/cppuhelper/source/propshlp.cxx:680 #16 0x00007f462b59bb77 in cppu::OPropertySetHelper::impl_fireAll(int*, com::sun::star::uno::Any const*, com::sun::star::uno::Any const*, int) (this=0x55f20b7e8098, i_handles=0x7ffd5b69320c, i_newValues=0x7ffd5b6934a8, i_oldValues=0x7ffd5b693198, i_count=1) at /home/julien/lo/libreoffice/cppuhelper/source/propshlp.cxx:568 #17 0x00007f462b59a64e in cppu::OPropertySetHelper::setFastPropertyValue(int, com::sun::star::uno::Any const&) (this=0x55f20b7e8098, nHandle=22, rValue=uno::Any("long": 10000)) at /home/julien/lo/libreoffice/cppuhelper/source/propshlp.cxx:543 #18 0x00007f462b59884b in cppu::OPropertySetHelper::setPropertyValue(rtl::OUString const&, com::sun::star::uno::Any const&) (this=0x55f20b7e8098, rPropertyName="FormatKey", rValue=uno::Any("long": 10000)) at /home/julien/lo/libreoffice/cppuhelper/source/propshlp.cxx:265 #19 0x00007f45f996faf0 in dbaui::OFieldDescription::copyColumnSettingsTo(com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet> const&) (this=0x55f20bf4f960, _rxColumn=uno::Reference to (dbaccess::OTableColumnWrapper *) 0x55f20b7e80a8) at /home/julien/lo/libreoffice/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx:623 #20 0x00007f45f99784c4 in dbaui::OTableController::alterColumns() (this=0x55f20b7931e0) at /home/julien/lo/libreoffice/dbaccess/source/ui/tabledesign/TableController.cxx:1070 #21 0x00007f45f99731d5 in dbaui::OTableController::doSaveDoc(bool) (this=0x55f20b7931e0, _bSaveAs=false) at /home/julien/lo/libreoffice/dbaccess/source/ui/tabledesign/TableController.cxx:356 Change-Id: I4363cdad7339eb2ad69f9839832b11f448dd989c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152258 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2023-04-28tdf#43369: Specific UI for collecting PostgreSQL connection settingsnirnay
strings.hrc is used to add the text visible in the GUI and hence coressponding strings have been defined for postgres GUI. dsntypes.cxx since a new GUI page has been created for postgres a new page routing has been inserted instead of it going to default Since oracle jdbc and mysql jdbc have almost the same GUI the oracle jdbc was used as reference since there is no middle page between the target GUI page, unlike in mysql jdbc. dsntypes.hxx corressponding page id has been added for postgres for routing. dbadmin.cxx new default postgres port id has been added added just like MySQL and defined like all. dsitems.hxx contains the DSID used dbadmin.cxx dbwizsetup.cxx this where the GUI page is being called for generation dbwizsetup.hxx holds the title page string UIConfig_dbaccess.mk includes the new postgres page postgrespage.ui is the UI page where the GUI part has been refered from specialjdbcconnectionpage.ui and the connection string has been taken from dbwizconnectionpage.ui instead of adding a label and edit option so that connection string prefix is handled in the GUI with pre-existing curledit.cxx DBSetupConnectionPage.hxx holds the declaration of all the functions called in the coressponding cxx file. The declaration is a mix of OGeneralSpecialJDBCConnectionPageSetup class from where the GUI is being handled and since there is no test connection from postgres the test driver has not been implemented, OConnectionTabPageSetup from which commit page has been inspired and OConnectionHelper is used to handle the connectionstring just like in the original class minus the file based system implementation. DbAdminminImpl.cxx is where the data is retrevied from GUI and and pasted at the back of the connection string which is now a usual postgres connection string. dbaccess.suppr the supression has been added for gtklabel of postgres which have no corresponding entry widget. Change-Id: Id60fd02a56b10c1cb9b09c9302c6ddf170be8493 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150546 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2023-04-25Add script to find unused using declarationsGabor Kelemen
As a complementer to clang-tidy-12 --checks="-*,misc-unused-using-decls" Pros: - simple, fast! - finds some more unused declarations, somehow - works on non-linux specific parts of the code - clang-tidy (for me) trips on files with external headers, this does not Change-Id: If2db989114ac5c2841ed2e89ff7bd7a9e419f567 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150612 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2023-04-20Run clang-tidy with misc-unused-using-decls on modules [d-o]*Gabor Kelemen
To remove unneeded using declarations. Via the simple script: for i in $(find $dirname -name "*cxx" -o -name "*hxx" ); do clang-tidy-12 --checks="-*,misc-unused-using-decls" "$i"; done Change-Id: Idd8aa3d3cfec456c4babb65e89af712051b4deb0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150609 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
2023-04-19loplugin::unusedmethodsNoel Grandin
Change-Id: I6a07860edb13588b83345babeb53675aedc43f7a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150607 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-03-06BaseMutex->std::mutex in OEmbedObjectHolderNoel Grandin
Change-Id: I0c05556e1d2585b48068094627be3e58a2640340 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148275 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-03-06BaseMutex->std::mutex in OPropertyForwardNoel Grandin
Change-Id: I9918bd4fbedb2f6517278c010b6ee66ba7f9c851 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148277 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-02-28flatten some internal classes in dbaccessNoel Grandin
no need for the pimpl pattern here Change-Id: I6e15dd7b68104b2848871c338d5560cb70c9c88d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147869 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-01-17XUnoTunnel->dynamic_cast in ODatabaseContextNoel Grandin
Change-Id: I5e20afd203c07d371599634b2b3239b38a4ecce2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145625 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-01-16XUnoTunnel->dynamic_cast in OContentHelperNoel Grandin
Change-Id: I3788af96cc8664d8afda2bd5eeaf85e9cd0cf374 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145618 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-01-16XUnoTunnel->dynamic_cast in ORowSetBaseNoel Grandin
Change-Id: I685d15982f56b336862da57ecfcbd9ac2d14838b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145616 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-01-16XUnoTunnel->dynamic_cast in OQueryDescriptorNoel Grandin
Change-Id: Ide46f159674ce84f6ecd8b9b0045a66a3b4ddd98 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145615 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-01-16XUnoTunnel->dynamic_cast in connectivityyNoel Grandin
Change-Id: Ibe5e87a1ef1bdc11451e8fe240d017f1ef60dfe6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145556 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2023-01-15Merge SvXMLAttributeList to comphelper::AttributeListMike Kaganski
And simplify the latter, to always use "CDATA" type (as the former did). "CDATA" was used in all cases but one, where an empty string was used. Change-Id: I1b3bfae40e29628e4094d9a6e58a69a66865874c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145526 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2023-01-13Base OSubComponent on cppu::WeakComponentImplHelperStephan Bergmann
...rather than on cppu::OComponentHelper (which derives from XAggregation) and then manually suppressing support for XAggregation in OSubComponent::queryInterface Change-Id: I6718d36f20579806b508c4bf5048b734643ad716 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145476 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2022-11-23loplugin:unusedfields make some fields privateNoel Grandin
this is one of the secondary analyses this plugin performs Change-Id: Iaa4424c2396470c6f1df85b0290fbffdda35fa08 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143177 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-11-11Drop a counterproductive const&Stephan Bergmann
...that was apparently left by accident by c7f8a54e05dab430cf2f5b3e1fa90e729c7a5601 "loplugin:moveparam in dbaccess", thwarting the use of std::move here. (I came across this code with an upcoming loplugin:constmove that flags suspicious uses of std::move involving const-qualified types.) Change-Id: I58cb6fc938efc470d6be6417d2dadd77989f1241 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142559 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2022-11-04tdf#54857 use OUStringConstExpr in XMLPropertyMapEntryNoel Grandin
which means we don't need to allocate a bunch of strings when building the property maps in xmloff Change-Id: I83cb013f816d9b7bcb0dd55c59e5151b33b91c9c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142192 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-10-28Typo: SERVICE_SDB_PREPAREDSTATMENT->SERVICE_SDB_PREPAREDSTATEMENT (dbaccess)Julien Nabet
Change-Id: Ifea148d85236fee8aa29146f07bb3d57e634a246 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141973 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2022-10-23tdf#151073 - enable firebird for appstore build w/o experimental modeChristian Lohmaier
also don't default to hsqldb as embedded database when a build is done without java support. Mainly to hide an UI bug - apparently the dialog should show a non-supported message for known embedded drivers at least that is what 04d1e80ac7091ec2bf31c8617e832d5fe15350be suggests " // this indicates it's really a type which is known in general, but not supported on the current platform // show a message saying so // eSpecialMessage = smUnsupportedType; insertDatasourceTypeEntryData( m_eCurrentSelection, sDisplayName ); // remember this type so we can show the special message again if the user selects this // type again (without changing the data source) m_eNotSupportedKnownType = m_pCollection->determineType( m_eCurrentSelection ); " but that doesn't work, at least not anymore. m_eNotSupportedKnownType was since removed, no attempts are made in showing an error/warning message returning the hsqldb driver results in an empty (no display string) entry as the default element in the dropdown in the dialog, that still allows to create a database file (but of course one that you cannot add any actual database tables to) without any error message. At the very least it is inconsistent with the rest of the dialog's code that clears the input name for stuff that shouldn't be shown. Change-Id: I8419888018be2a556c49d32e40f02c0ac1801930 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141631 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2022-09-29split utl::TempFile into fast and named variantsNoel Grandin
which makes it easier to know what each variant requires to stay on it's happy path Change-Id: I3275a2543573367714bc78092e882f6535507285 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140469 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-27use more string_view in dbaccessNoel Grandin
Change-Id: Id0b41d57015e8e2542b47d3a09ca8f13d090dbca Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140621 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-10convert EmbeddedMacros to scoped enumNoel Grandin
Change-Id: I7e24b5ad53853ff7989f262a3b914b2082ac5ec4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139733 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-09convert CursorMoveDirection to scoped enumNoel Grandin
Change-Id: I9ad59207fab6d3988b8c8106aec6c4fac21dc9d6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139734 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-07convert ObjectType to scoped enumNoel Grandin
Change-Id: I1c103aebe02a41ed4fa59a72950cb55d3c6c93d6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139544 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-05tdf#147021 Use std::size() instead of SAL_N_ELEMENTS() macrojsala
Also change some integer by std::size_t Change-Id: I6a0fda3ba44815aac3312d523be04f4f973ce84f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137142 Tested-by: Jenkins Reviewed-by: Hossein <hossein@libreoffice.org>
2022-09-05dbaccess::DataSupplier doesn't need a pimplNoel Grandin
it is module private Change-Id: I6d1479872e715d081030601b88ad4be38ab0f011 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139378 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-05ObjectNameApproval doesn't need a pimplNoel Grandin
it is already module private Change-Id: Ic597fa86ee83a5d22d88c29befc3d54ea6eaecf8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139364 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-09-05RowSet doesn't need a pimplNoel Grandin
it is module internal Change-Id: I906c579c9303ae7e770559ee37c8bb253738d1f0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139363 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>