summaryrefslogtreecommitdiff
path: root/dbaccess
AgeCommit message (Collapse)Author
2018-02-26convert remaining ErrorBox to weld::MessageDialogCaolán McNamara
and convert remaining QueryBox to weld::MessageDialog Change-Id: Ifb4c316dee8eabf57c4940c44e29c65a2781aa6c
2018-02-25convert remaining InfoBox to weld::MessageDialogCaolán McNamara
Change-Id: I91d828e38d96264cf4a76f30940942556b8f78d8 Reviewed-on: https://gerrit.libreoffice.org/50205 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-02-25convert all help responses to gtk's -11Caolán McNamara
and ok responses to gtk's -5 and cancel responses to gtk's -6 and close responses to gtk's -7 and yes responses to gtk's -8 and no responses to gtk's -9 Change-Id: Ia1a261a3a711ed9f5d8c0b0c639897c3064bb08c Reviewed-on: https://gerrit.libreoffice.org/50206 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-02-22weld native message dialogsCaolán McNamara
just the straight-forward MessageDialog cases first a) remove border_width from message dialog .ui so as to take the default border width b) retain 12 as default message dialog border for vcl widget case c) remove layour_style from message dialog button boxes so as to take the default mode (a no-op for vcl widget case) d) use gtk response ids (vcl builder will converts to vcl ones) Change-Id: I7de281093a1b64f92f71ca11e7cbba42bb658154 Reviewed-on: https://gerrit.libreoffice.org/50143 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-02-22loplugin:redundantcopy extend to ColorNoel Grandin
Change-Id: I224cc955d49ee100d328e0171da710f38068d2d4 Reviewed-on: https://gerrit.libreoffice.org/50114 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-02-21New loplugin:nestedunnamedStephan Bergmann
Change-Id: Ifb434589ef08428ce609bc7a40b015d4df13224c Reviewed-on: https://gerrit.libreoffice.org/50048 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-02-16Revert "loplugin:changetoolsgen in dbaccess..desktop" and reapply pluginNoel Grandin
because I (a) forgot to insert parentheses which changes the meaning of some expressions and (b) I now use the AdjustFoo calls when changing unary operations, which reads much better This reverts commit a9ca38bdf7ff9d15529b5903e640987fc14c0fa7. Change-Id: I662ef2f1100a06a68decb2c71975fbc61aeaa47d Reviewed-on: https://gerrit.libreoffice.org/49847 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-02-14loplugin:changetoolsgen in dbaccess..desktopNoel Grandin
Change-Id: I713a320e46f93dedd11266ac12e52110d13f451a Reviewed-on: https://gerrit.libreoffice.org/49655 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-02-05loplugin:useuniqueptr in OTableNoel Grandin
use rtl::Reference here since these are reference counted data structures, and we hand out references to me via our API Change-Id: I8f69dde2db08519cb3d9de20b4ad54462e3ecc98 Reviewed-on: https://gerrit.libreoffice.org/49180 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-02-01tdf#42949 Remove unneeded helpids.h headers (1/3)Gabor Kelemen
A side effect of the .ui migration is that we use a lot less HIDs in the code. A lot of files still contain helpids.h includes even if no actual HID is referenced. This cleans up directories b* - e*. Found with: git grep helpids.h | cut -d : -f 1 | xargs grep -c HID_ | grep :0$ Change-Id: I221d22f68584115d71660a97c4f108595625d12c Reviewed-on: https://gerrit.libreoffice.org/46868 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2018-02-01dbaccess: MSVC: pragma warning: make more specific, remove obsoleteMike Kaganski
Change-Id: I0066b2de769a412cb04bcec7cdd8401f42b9dcf3 Reviewed-on: https://gerrit.libreoffice.org/48972 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-01-31Fix typoAndrea Gelmini
Change-Id: I1e78c05cc78c03c1b5578342f7480405f6992c68 Reviewed-on: https://gerrit.libreoffice.org/48999 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-31tdf#114596 dbaccess: fix mysterious dataloss bugMichael Stahl
OBookmarkContainer actually re-uses the reference count of ODatabaseSource, so converting ODatabaseSource::m_aBookmark to Reference created a cycle, which somehow causes the dataloss, because evidently something as important as storing the data must be done in the destructor. (regression from 2660d24a07866e083c5135ea263030f3e3a2e729) Change-Id: I4cad01dc9cdaf405c1eb31d6c0e161eb6712b78f
2018-01-29Fix typosAndrea Gelmini
Change-Id: I13b1c0f190b9ebab99e88f90026980fcb2c81c41 Reviewed-on: https://gerrit.libreoffice.org/48833 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-29Related tdf#115273: Set NULLJulien Nabet
instead of "Set null" to explicit the fact that NULL is a keyword Change-Id: Iab393ffc1af07d027ef93168c8de58f3635af11c Reviewed-on: https://gerrit.libreoffice.org/48817 Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu> Tested-by: Jenkins <ci@libreoffice.org>
2018-01-27Add HSQLDB schema importTamas Bunth
It can be enabled by initializing the DBACCESS_HSQL_MIGRATION variable. Create new library "dbahsql" which is responsible for migrating the embedded hsql database to any database covered by sdbc. The hsqldb schema is stored in a file named "script" in form of SQL statements. The SQL statements used by DBMS's differ mostly by the defined types. Because of that, only the create statements need to be parsed, alter statements will work (with a little luck) without actually modifying it. User / security settings which can occur in the script file (e.g. GRANT statements) are dropped. Statements starting with SET are also dropped (they are hsql specific stuff) Change-Id: I6a22942e8a9a76765f80e50f0ad68f4d72e1ff9d Reviewed-on: https://gerrit.libreoffice.org/48260 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Bunth <btomi96@gmail.com>
2018-01-26Fix typosAndrea Gelmini
Change-Id: I334f0bd5636940ea8105dcf93b95b3af28894aad Reviewed-on: https://gerrit.libreoffice.org/48546 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-25Fix typosAndrea Gelmini
Change-Id: Ieef0e3f21eb12cb5b72d39da4bc0a8c60dd0d5ce Reviewed-on: https://gerrit.libreoffice.org/48545 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-24tdf#115080 menu id collisionCaolán McNamara
21 collides with the pattern field menu id Change-Id: Ia90995861adabbe1615e24ee10defe25cee76c56 Reviewed-on: https://gerrit.libreoffice.org/48461 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-01-22remove some sal_Bool remnantsNoel Grandin
Change-Id: I0a9637aca523a73fbdbbd22f9ad735d6d1ba6898 Reviewed-on: https://gerrit.libreoffice.org/48273 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-19inline some definesNoel Grandin
which don't add any value anymore Change-Id: I45977d972d4d02926630b749d3ec736416138cf5
2018-01-19loplugin:unusedmethods also check for functions returning boolNoel Grandin
we were previously excluding them Change-Id: I48a68799b0de60b4995fae541eb363e043d4dd11 Reviewed-on: https://gerrit.libreoffice.org/48167 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-18Fix reg from 4cb3e1c05a16af3dad03db9d789dc7ea061b33cfJulien Nabet
Change-Id: I853a949e68d192c48a90321a8b3b75a5d443638b Reviewed-on: https://gerrit.libreoffice.org/48111 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins <ci@libreoffice.org>
2018-01-17Use for-range loops in QueryDesignView (dbaccess)Julien Nabet
Change-Id: I713654ad7f1139c6f0cb46304a6958020c37f9c7 Reviewed-on: https://gerrit.libreoffice.org/48069 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-17coverity#1427632 try silencing Using invalid iteratorCaolán McNamara
Change-Id: I74387fd761f170d61e490418f856bfffd5dd8401
2018-01-17loplugin:unnecessaryparen extend to delete statementsNoel Grandin
Change-Id: Ic4383ea948876a26f791f0e5b0110cef978a26e1 Reviewed-on: https://gerrit.libreoffice.org/48027 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-17Handle focus_on_click glade property for buttonsMaxim Monastirsky
It maps to our WB_NOPOINTERFOCUS. Change-Id: Ib00e696801b72de2c931e282ed8d50c972fa59fb Reviewed-on: https://gerrit.libreoffice.org/47990 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
2018-01-16Fix typosAndrea Gelmini
Change-Id: Id3d1a07922d4ca05e3bbf61d4b5797a30fc5b23a Reviewed-on: https://gerrit.libreoffice.org/47872 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-16Fix typosAndrea Gelmini
Change-Id: I078626eaa3155cc429320cc8c1532003b382b22a Reviewed-on: https://gerrit.libreoffice.org/47855 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-15More loplugin:cstylecast: dbaccessStephan Bergmann
Change-Id: Ic59e95a28606d42eca250fb0bed4c5b821b266cf
2018-01-12More loplugin:cstylecast: dbaccessStephan Bergmann
auto-rewrite with <https://gerrit.libreoffice.org/#/c/47798/> "Enable loplugin:cstylecast for some more cases" plus solenv/clang-format/reformat-formatted-files Change-Id: I96df8923f7791288bbd350d75582a9220006ece6
2018-01-11tdf#114955: Fix primary key management in copy tableJulien Nabet
When we chose to create a primary key, be sure the other existing columns won't be in primary key Change-Id: I523f1b3a4b56c92d48b65cb3d83793b5459c630c Reviewed-on: https://gerrit.libreoffice.org/47732 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu>
2018-01-11Use for-range loops in dbaccess (part2)Julien Nabet
Change-Id: I7a247584a88fa516c7d28068b3d860499f090c92 Reviewed-on: https://gerrit.libreoffice.org/47189 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-11convert (a>b?a:b) to std::max(a,b)Noel Grandin
with something like: git grep -nP '(.*)\s*>\s*(.*)\s*\?\s*\g1\s*:\s*\g2' Change-Id: I60b9a3a2a09162bc0de4c13fdde2c209696e5413 Reviewed-on: https://gerrit.libreoffice.org/47602 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-10tdf#113923: don't use twice a new column in table copyJulien Nabet
In the case where: 1: we enabled the creation of a primary key 2: we come back here from the "Back" button of the next page, we want to avoid to list the new column generated in the next page So we must check added columns in right panel must exist in the table Change-Id: I467007941b03811381a216c1ab3de8fe729f9b9b Reviewed-on: https://gerrit.libreoffice.org/47684 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu>
2018-01-03loplugin:passstuffbyref more return improvementsNoel Grandin
slightly less restrictive check when calling functions Change-Id: I35e268ac611797b1daa83777cda02288a635aa32 Reviewed-on: https://gerrit.libreoffice.org/47259 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-31tdf#114755: Remove extra parenthesisJulien Nabet
from SELECT block of INSERT INTO <> SELECT <> Change-Id: Ibe3c3f5f2fbc15388c716ae262e87137958c1a7e Reviewed-on: https://gerrit.libreoffice.org/47218 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-30loplugin:passstuffbyref improved return in cui,dbaccessNoel Grandin
Change-Id: I1193ff91ccd548acf9492d9701b6411a24d6763e Reviewed-on: https://gerrit.libreoffice.org/47194 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-30Incrementing end iterator has undefined behavior (dbaccess/cacheset)Julien Nabet
Change-Id: I9f4cdacd87cc4802b13c99c15e1d24d11285a375 Reviewed-on: https://gerrit.libreoffice.org/47188 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-29Fix typosAndrea Gelmini
Change-Id: I0e56430afa65b6b5826d56212ac501c0244fce9b Reviewed-on: https://gerrit.libreoffice.org/47145 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-28Use returned iterator (dbaccess/rowsetcache)Julien Nabet
Change-Id: If53bbc8e3cdbbf71bed0d343f1ff358b72c46d21 Reviewed-on: https://gerrit.libreoffice.org/47147 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-28Optimize a bit RowSetCache (dbacess)Julien Nabet
Change-Id: I051cb40b5dd854a4a104eae7124564cab8a35de1 Reviewed-on: https://gerrit.libreoffice.org/47151 Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu> Tested-by: Jenkins <ci@libreoffice.org>
2017-12-28Use for-range loops in dbaccessJulien Nabet
Change-Id: I0be3aba4f03dcaba188670548901e4aef59c5ec0 Reviewed-on: https://gerrit.libreoffice.org/47148 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-28tdf#114702 don't use XMultipleResultset unless DatabaseMetaData says we canLionel Elie Mamane
Change-Id: Icec98d35c2f60adf4a31e492c6cb708e82e47a58 Reviewed-on: https://gerrit.libreoffice.org/47080 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-28dbaccess OStatementBase: correctly check database metadataLionel Elie Mamane
the previous test didn't make any sense: * if xMeta.is(), then the test evaluated to false * if !xMeta.is(), then it called supportsMultipleResultSets (or supportsBatchUpdates, respectively) on a NULL pointer, which guaranteed a segfault / assert. Change-Id: I6d6b93350557936b924a286732ae6d4f5ab2ce56 Reviewed-on: https://gerrit.libreoffice.org/47118 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-27Use for-range loops in dbaccess/RowSetJulien Nabet
Change-Id: I27c280eaaf5ff6a4c1970e91ae227206bb712cea Reviewed-on: https://gerrit.libreoffice.org/47073 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-27Use for-range loops in dbaccess/OptimisticSetJulien Nabet
Change-Id: Iccd0848e772867ece243444dc697e264907b28d4 Reviewed-on: https://gerrit.libreoffice.org/47072 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-26Use for-range loops in dbaccess/KeySet (2nd pass)Julien Nabet
+ remove an unused var Change-Id: I62659f4ca5ac734f46d00e59b12fb6f54a177ecb Reviewed-on: https://gerrit.libreoffice.org/47071 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-22Use for-range loops in dbaccess/KeySet (1st pass)Julien Nabet
+ remove an unused var + fix a slight indent pb Change-Id: Ie6e801c9d2b7ce6e7f5d352b2175fa9d7d6b9c7d Reviewed-on: https://gerrit.libreoffice.org/46995 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-22lokdialog: Allow switching language of some of the ResMgr's.Jan Holesovsky
This way, it is possible to have all the strings translated in dialogs even when different users use different languages. [It was already possible to have different languages previously, but not everything in the dialog has switched - like the buttons at the bottom of the dialogs etc.] Change-Id: I29a5ae6d31a370eec60397884200b684ec1bf5b9 Reviewed-on: https://gerrit.libreoffice.org/46417 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/46979 Tested-by: Jenkins <ci@libreoffice.org>