11701 Commits

Author SHA1 Message Date
Julien Nabet
5e12e630ff Use const_iterator when possible
Change-Id: I7454a8e5547da95b747eeb3b1d9dabe3a56a69f3
Reviewed-on: https://gerrit.libreoffice.org/23567
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2016-03-28 13:26:29 +00:00
Noel Grandin
26d0274784 loplugin:constantparam in dbaccess
Change-Id: I81c1385ec6881fe9b8f75b5506268f5e7b03e2cb
2016-03-23 11:22:34 +02:00
Lionel Elie Mamane
57bf3a3340 off-by-one error: columns are numbered from one, but the array from 0
Change-Id: I14ef451999fa1f9d57757a9e231fc66be4e53f3a
2016-03-21 16:43:16 +01:00
Noel Grandin
c91b103930 convert SvButtonState to scoped enum
Change-Id: I601f9e2fe33e85cf3f7dc52ee20d68202bd2b09d
2016-03-18 12:46:35 +02:00
Noel Grandin
0008c67004 drop unused params from SvLBoxItem and all it's subclasses
looks like this is fallout from commit
ac7acb0a "Merged SvTreeListBox and SvLBox."
(in year 2012)

Change-Id: Iaebeae64fc7cd3ba11f5f45b53bcb65bf906e906
2016-03-18 11:03:00 +02:00
Noel Grandin
dd351c8524 loplugin:constantparam in dbaccess
Change-Id: Icfe7d3d4630f4b5b3b2491ba56245257bad31bb8
Reviewed-on: https://gerrit.libreoffice.org/23349
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-18 08:33:50 +00:00
Caolán McNamara
4331b137fd Resolves: tdf#92617 don't crash if insertRow gets triggered during insertRow
insertRow notifies listeners that it is going to insert contents,
if a script listens to that and eventually triggers insertRow again then
one inside the other causes corruption and pestilence

Change-Id: I6b568d0a67f6108536d58c407b79d02bf29f297a
2016-03-17 14:51:27 +00:00
Noel Grandin
78f0d15893 loplugin:constantparam in xmloff/
Change-Id: I376f1d4ac65de584f9caa6ba8e25e43216374112
Reviewed-on: https://gerrit.libreoffice.org/23295
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-16 11:35:38 +00:00
Noel Grandin
b47cb646ff loplugin:constantparam
Change-Id: I270e068b3c83e966e741b0a072fecce9d92d53f5
2016-03-15 08:27:25 +02:00
Susobhan Ghosh
bf8f926acc tdf#95845 Use CommandInfoProvider to receive UNO command labels
Added GetCommandPropertyFromModule to CommandInfoProvider.
Removed GetCommandText.

Change-Id: Ie987984b6465d540029196df371c0c0467999a59
Reviewed-on: https://gerrit.libreoffice.org/22918
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2016-03-14 13:48:26 +00:00
Noel Grandin
218cd09611 inline some use-once macros
Change-Id: I7ebd8fe70b083a772118a1aab8cdfbf795d6f1e5
Reviewed-on: https://gerrit.libreoffice.org/23235
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-14 11:06:48 +00:00
pasqualm
a6ca4ec7f5 tdf#97978: add support for opening mde and accde files in base
This patch modifies the base 'open existing database' wizard so accde and mde files
can be chosen as targets for access and access 2007 databases. Both file types are
the runtime-only equivalents to accdb and mdb files so base can use them in the
same way as does with the former

Change-Id: I5b6002089a2d3c19498ff6e05bae3facc5a4e2d0
Reviewed-on: https://gerrit.libreoffice.org/22957
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-12 14:40:06 +00:00
Julien Nabet
1151fec7a8 Let's use the iterator return by erase method (final)
Change-Id: I1934b0c2a9ae9fa089d7e9ded4a289908fb2709a
Reviewed-on: https://gerrit.libreoffice.org/23173
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-12 14:30:32 +00:00
Wastack
018c6adf85 tdf#97966: Remove 'static' keywords
Change-Id: I0d9837a7ccecd606e0d43b53f8b920547b0d0bcd
Reviewed-on: https://gerrit.libreoffice.org/23132
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-11 08:56:20 +00:00
Markus Mohrhard
e94d5233dd work on sane lifecylce for SfxFilter
all SfxFilter instances should now be hold inside of a std::shared_ptr.

This fixes a number of huge memory leaks in the test framework and
removes one huge source of memory issue in sfx2. SfxMedium contains a
pointer to the SfxFilter but does not own. Therefore it is required that
any SfxFilter belonging to a SfxMedium lives longer. However this seems
to work mostly by hoping that all SfxFilter instances are stored in a
global array. As we have seen with the tests this is not true (there are
also some cases inside of sd that seem to not follow that pattern as
well).

Change-Id: I12fd04a504cc4efc0a94967abd91c6fe2c6a8ce8
Reviewed-on: https://gerrit.libreoffice.org/23140
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2016-03-11 06:38:15 +00:00
Caolán McNamara
29fc44c6f8 fix debugging stl iterators assert in bibliography toolbar
bibliography: click autofilter toolbar icon to get drop down, select an
entry and assert on use of invalid iterators.

In this specific case we want to reset them all, so add a new simpler
method to just do that and not do the (always supposed to be true) comparison

note: in ORowSet::checkUpdateIterator
at m_aCurrentRow = m_pCache->m_aInsertRow; these iterators are then invalid
the whole iterator caching and fiddling here is concerning.

Change-Id: I74952896f47ac482b6bacb26afe5b1cfcf6bc49c
2016-03-09 09:50:08 +00:00
Noel Grandin
c8a93253e4 remove unused NOT_POOLABLE enum value
and simplify the resulting SfxItemInfo field down to a single bool

Change-Id: I73e24e83d39afc7660ac85872ba96bc790713cb2
Reviewed-on: https://gerrit.libreoffice.org/23058
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-09 09:46:53 +00:00
Noel Grandin
1b1080fe8a loplugin:constantparam in dbaccess
Change-Id: I44b5a586a1b0da47e032dff097ebf545f5fe76fc
2016-03-09 10:07:47 +02:00
David Ostrovsky
adfa772549 Add missing includes
These include were needed to compile on Windows, MSVC 14.0 with
clang-cl.

Change-Id: I4ca5cec8314920e90fcca6fa69ec4df87d680f29
Reviewed-on: https://gerrit.libreoffice.org/23044
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-09 07:53:56 +00:00
Stephan Bergmann
5c1234eac2 loplugin:nullptr
Change-Id: I0c78ddab5efb7a295ccf42b6539b5aa3b7009bf9
2016-03-08 14:43:11 +01:00
Rohan Kumar
576ab77255 tdf#91794 Remove OSL_DEBUG_LEVEL > 1 conditionals
I either replaced OSL_DEBUG_LEVEL > 1 with OSL_DEBUG_LEVEL > 0
statements or i used SAL_INFO(..)s

Change-Id: Iefb6b83e86e1767e55600b6e1989ee91207fb220
Reviewed-on: https://gerrit.libreoffice.org/23000
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: jan iversen <jani@documentfoundation.org>
2016-03-08 13:31:09 +00:00
David Tardon
d795f83695 expand src templates
Change-Id: Id35caa8b8ed0c2f7e4d868f5c87a2a0f331cb352
2016-03-07 17:43:28 +01:00
David Tardon
24905f42b9 expand src templates
Change-Id: I13afaa9d0c7c9b46b3ebaedf299de41bed551e7c
2016-03-07 17:43:28 +01:00
Noel Grandin
359e0b47a0 loplugin:unuseddefaultparams
Change-Id: Ia414f7845425ef73859ed04853378e96cc738795
Reviewed-on: https://gerrit.libreoffice.org/22971
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-07 09:16:00 +00:00
David Tardon
71e1a44ba1 expand src templates only used in a single place
Change-Id: If10e2fb1448867e79df3ddc962f93b904af94b3d
2016-03-07 08:50:58 +01:00
Noel Grandin
70f87284c6 improve defaultparams loplugin
to catch calling params with defaults like "= OUSString()"

Change-Id: Iad060e318ed492c22f8be44e326174fe6d28fff9
Reviewed-on: https://gerrit.libreoffice.org/22932
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-07 05:57:17 +00:00
Noel Grandin
37a6bafea8 loplugin:unuseddefaultparam in various
Change-Id: I03d7381aad055cbe9bd905e4082586073f4112e0
Reviewed-on: https://gerrit.libreoffice.org/22900
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-07 05:56:59 +00:00
Noel Grandin
e13ba2d41d loplugin:unuseddefaultparams in dbaccess
Change-Id: I5f417aea43b4aa841ee45e947b982e6341c7b18b
2016-03-03 08:11:02 +02:00
Julien Nabet
6689a9aaf7 Typo: aCompoments->aComponents
Change-Id: Ied7413a74b2ed0ea7a6375760c4477ce6f17a4de
2016-02-26 20:33:52 +01:00
Noel Grandin
414a66587b convert StandardSQLState to scoped enum
Change-Id: Ia0a1526140cfed35a73a6fea1a173d2fb5005960
2016-02-25 13:50:26 +02:00
Noel Grandin
960d4ebf76 convert SQLNodeType to scoped enum
Change-Id: I622e55622d38e6017993c8bc52625c85d0f74d74
2016-02-25 13:50:26 +02:00
Noel Grandin
d6c28b11e5 convert OSQLStatementType to scoped enum
Change-Id: I2df117cf0f405e88899e7ccab380156284720449
2016-02-25 13:50:25 +02:00
Noel Grandin
ccb8b83070 convert FilterComponent to scoped enum
and simplify the overly-general logic in FilterManager

Change-Id: I2cbd9db6a53894cd13713a5cc0d1807cec456848
2016-02-25 13:50:25 +02:00
Noel Grandin
bf7690bc1b convert EComposeRule to scoped enum
Change-Id: I5a2e4f6f6f0f353c75dff85e865608b12c2104f9
2016-02-25 13:50:25 +02:00
Noel Grandin
761e55d368 convert SQLExceptionInfo::TYPE to scoped enum
Change-Id: I2f21a742bc649fc42f89aebac2691c6054cd20d8
2016-02-25 13:50:25 +02:00
Noel Grandin
4dd65f861d convert InternationalKeyCode to scoped enum
Change-Id: I2eba99ebb86003f1f5ddefafb4cd191b29853819
2016-02-25 13:50:25 +02:00
Noel Grandin
6a9046d02e convert ErrorCode to scoped enum
Change-Id: I37d2dd0b84fce229b548bbe941cfdd1169170af9
2016-02-25 13:50:24 +02:00
Noel Grandin
c45d3badc9 new loplugin: commaoperator
Change-Id: I03f24e61f696b7619855e3c7010aa0d874e5a4ff
2016-02-23 08:08:56 +02:00
melikeyurtoglu
6e2de428a4 tdf#57950 Replace chained O(U)StringBuffer::append() with operator+
Change-Id: I2576c997d5b82fd8bdfd0c9430c7a1e11d7e07df
Signed-off-by: melikeyurtoglu <aysemelikeyurtoglu@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/22049
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2016-02-18 21:37:07 +00:00
David Ostrovsky
a3c70e760f Fix missing iterator include on MSVC 14.0
Change-Id: I55de612aef52038fd9979426950d4ae4131ca586
Reviewed-on: https://gerrit.libreoffice.org/22448
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: David Ostrovsky <david@ostrovsky.org>
2016-02-17 23:43:45 +00:00
Noel Grandin
2087484c65 use consistent #define checks for the Windows platform
stage 2 of replacing usage of various checks for the windows platform
with the compiler-defined '_WIN32' macro

In this stage we focus on replacing usage of the WIN macro

Change-Id: Ie8a4a63198a6de96bd158ecd707dadafb9c8ea84
Reviewed-on: https://gerrit.libreoffice.org/22393
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-02-17 11:33:57 +00:00
Arnold Dumas
53bf3ea58e tdf#57950: Replace chained O(U)StringBuffer::append() with operator+
Change-Id: Ic76cf0130ebec4cf723b83d82f59ae45bfcb3ea1
Reviewed-on: https://gerrit.libreoffice.org/22350
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-02-15 07:38:21 +00:00
Noel Grandin
d15d523d07 sequence->vector in OCacheSet
Change-Id: I61c6486d42dbc404355809a80943885457e79384
Reviewed-on: https://gerrit.libreoffice.org/22184
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-02-09 13:49:19 +00:00
Chris Sherlock
a238b1f8d3 Remove excess newlines
A ridiculously fast way of doing this is:

for i in $(pcregrep -l -M -r --include='.*[hc]xx$' \
  --exclude-dir=workdir --exclude-dir=instdir '^
{3,}' .)
do
    perl -0777 -i -pe 's/^
{3,}/

/gm' $i
done

Change-Id: Iebb93eccbee9e4fc5c4380474ba595858a27ac2c
Reviewed-on: https://gerrit.libreoffice.org/22224
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-02-09 08:18:05 +00:00
Chris Sherlock
538f276ae0 Formatting changes across all modules
+ Removed comment cruft
+ Tab formatting in number of files
+ Some commented out code removed
+ Tab characters replaced with spaces
+ Newline cleanup in quite a few files
+ Tweak header guard #endifs

Change-Id: I3208ff2f047da890edcc49b73389aca22442f5fc
Reviewed-on: https://gerrit.libreoffice.org/22221
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-02-09 08:11:34 +00:00
Noel Grandin
b14224fe97 loplugin:unusedmethods
using an idea from dtardon:

<dtardon> noelgrandin, hi. could you try to run the unusedmethods clang
plugin with "make build-nocheck"? that would catch functions that are
only used in tests. e.g., i just removed the whole o3tl::range class,
which has not been used in many years, but htere was a test for it...
<noelgrandin> dtardon, interesting idea! Sure, I can do that.

Change-Id: I5653953a426a2186a1e43017212d87ffce520387
Reviewed-on: https://gerrit.libreoffice.org/22041
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-02-08 06:08:14 +00:00
Andrea Gelmini
534b2a4b58 Fix typos
Change-Id: Ice72f8d9971e15dd6ef365e64cd567b8581a92d3
Reviewed-on: https://gerrit.libreoffice.org/21797
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2016-02-05 06:48:38 +00:00
Chris Sherlock
697d445ed0 vcl: take into account the font width is the average font width
I'm changing the Font class function names:

- SetSize       -> SetFontSize
- GetSize       -> GetFontSize
- SetHeight     -> SetFontHeight
- GetHeight     -> GetFontHeight
- SetWidth      -> SetAverageFontWidth
- GetWidth      -> GetAverageFontWidth

That's because it really makes no sense to say that there is a
single constant font width because obviously proportional fonts
don't have one - the best we can do is an average font width,
which is what folks like Microsoft sort of do already. On a fixed
font, the average is still accurate, for obvious reasons :-)

I'm also not a fan of GetSize/SetSize as I find it a might too
generic.

Change-Id: Ib80a604ba62d6883fd6cbc7994da763976be5c70
Reviewed-on: https://gerrit.libreoffice.org/22069
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-02-04 03:17:26 +00:00
Markus Mohrhard
3d3204be2c fix previous commit
Change-Id: I3e3b0cf703162b5f01148aced9a1d5faabb5d50d
2016-02-03 05:31:25 +01:00
Jochen Nitschke
bd76d319bb remove bogus nullprt checks for pContext
reported by Cppcheck

Change-Id: I737c2bd7be197ef9d0b29b922acd8021fefb7af6
Signed-off-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
Reviewed-on: https://gerrit.libreoffice.org/22059
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2016-02-03 02:17:32 +00:00