Commit Graph

356 Commits

Author SHA1 Message Date
Stephan Bergmann
178622f47c loplugin:salbool
Change-Id: I14a902c644c467d8e02474e5d0ba8d3dced2860f
2016-04-22 09:30:37 +02:00
Stephan Bergmann
ed467869d8 loplugin:salbool: Automatic rewrite of sal_False/True
Change-Id: Idf27ee5370f1fa24adf22908d9e801c7d40db935
2016-04-20 17:25:42 +02:00
Stephan Bergmann
7d8bdf8462 Clean up framework/inc/dispatchcommands.h
Change-Id: I6a9a8ae34c2f5abafd4192287fb12d4289a761ff
2016-04-18 17:32:45 +02:00
Noel Grandin
789055bc2a clang-tidy performance-unnecessary-copy-initialization
probably not much performance benefit, but it sure is good at
identifying leftover intermediate variables from previous
refactorings.

Change-Id: I3ce16fe496ac2733c1cb0a35f74c0fc9193cc657
Reviewed-on: https://gerrit.libreoffice.org/24026
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-18 07:37:31 +00:00
Noel Grandin
f045c536db clang-tidy performance-unnecessary-value-param in framework
Change-Id: I80987ea1bfac7478574de46ee30fc58fcc17eb68
2016-04-12 11:56:07 +02:00
Stephan Bergmann
f57c9921de Get rid of BaseHash wrapper (to unbreak Windows build)
Change-Id: Ieae7d6af7a4753958ebf2aeae9d2ae6fafe5efe9
2016-04-07 18:14:53 +02:00
Noel Grandin
3f7f497192 sequence->vector in framework
Change-Id: I457c3da4f4a31f58d688dcd96a2ccfc36518490d
Reviewed-on: https://gerrit.libreoffice.org/23692
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-01 07:33:45 +00:00
Maxim Monastirsky
21b92f386c MenuDispatcher::m_pMenuManager is always nullptr
... as shown by 7da15debe3.
Which means that MenuManager is unused, and MenuDispatcher
does nothing useful.

Change-Id: Ic85619531054a573d971d38b52609e1cbcaf780c
Reviewed-on: https://gerrit.libreoffice.org/23117
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2016-03-10 15:23:31 +00:00
Noel Grandin
7da15debe3 loplugin:constantparam in framework
Change-Id: I41c83b6214e3af7b3a40c8e00df5f100e39ebad7
2016-03-10 10:09:59 +02:00
Noel Grandin
7607b608d6 loplugin:unuseddefaultparam in framework
Change-Id: I4c5baa6f524e3382794c4844b7444904cc38584a
2016-03-02 07:57:38 +02:00
Chris Sherlock
01aa78cf08 vcl: cmdevt.[hc]xx -> commandevent.[hc]xx
Change-Id: I77b30f28ae5a6fad360d7cada9acfaa9c324408b
Reviewed-on: https://gerrit.libreoffice.org/22216
Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-02-08 21:41:17 +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
shubhamtibra
5d4f1f6f63 tdf#96949 Remove global static variable m_bPreferrFirstInterceptor and unused code
Remove global static variable "m_bPreferrFirstInterceptor" which is always true,
and remove the ifs where it is false.

Change-Id: I54dcea7a6010c825a66020ec3f7448bb32d120b8
Reviewed-on: https://gerrit.libreoffice.org/21519
Reviewed-by: jan iversen <jani@documentfoundation.org>
Tested-by: jan iversen <jani@documentfoundation.org>
2016-01-16 17:55:31 +00:00
Andrea Gelmini
64d624b651 Fix typos
Change-Id: I9a5940027423ff0791fa7da0b79b617412ce6b86
Reviewed-on: https://gerrit.libreoffice.org/21209
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2016-01-10 14:17:20 +00:00
Noel Grandin
1d5c39192e new loplugin:unusedfields
run it over the framework module

Change-Id: I1220a4be0936ba30136ce22ffd78633c8a7b9d35
2015-11-20 10:12:58 +02:00
Noel Grandin
25aec383f9 use initialiser for Sequence<OUString>
replaced using:
git grep -lP 'Sequence.*OUString.*\(\s*1\s*\)'
| xargs perl -0777 -pi -e
"s/Sequence<\s*OUString\s*> (\w+)\(\s*1\s*\);
.*\[0\] = (\S+);/Sequence<OUString> \1 { \2 };/g"

Change-Id: I20ad0489da887a9712982531c3b127339bb8b3b9
Reviewed-on: https://gerrit.libreoffice.org/19969
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-11-15 12:18:55 +00:00
Stephan Bergmann
06c5c63020 loplugin:nullptr (automatic rewrite)
Change-Id: Ie178c474921c1695927a9b01a9972baf09fbb73d
2015-11-10 10:31:27 +01:00
Noel Grandin
97a392a036 fix build
after my commit 7408498de3
 "loplugin:stringconstant"

Change-Id: I1354207e1ecb6ebc76fcda3ed8eb8f369180eae8
2015-11-02 15:11:49 +02:00
Noel Grandin
7408498de3 loplugin:stringconstant
Change-Id: I865efc1884b82d430fe7df2e432d43f5425a83d4
2015-11-02 14:50:33 +02:00
Noel Grandin
5797d29e9e use uno::Reference::set method instead of assignment
Change-Id: Ic979f8a7734d0ef7a915d47a875cdcd460c0cc58
2015-11-02 12:23:16 +02:00
Noel Grandin
d191d1f9b6 com::sun::star->css in framework
Change-Id: If5a77db83fcbef5ed436f2043ddeb7c515a840dc
Reviewed-on: https://gerrit.libreoffice.org/19356
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-10-14 06:37:16 +00:00
Andrea Gelmini
a18fc918d5 Fix typos
Change-Id: I051caee9ec6181074201ac4a8cb6fcec4fdf2293
Reviewed-on: https://gerrit.libreoffice.org/18951
Reviewed-by: Oliver Specht <oliver.specht@cib.de>
Tested-by: Oliver Specht <oliver.specht@cib.de>
2015-09-30 13:50:06 +00:00
Noel Grandin
6d8124e30c convert Link<> to typed
and remove unused UserEvent class

Change-Id: Ic61c5eef75c36393dbbaa92d93163eab89021ee3
2015-09-22 20:21:55 +02:00
Noel Grandin
99bfc363a6 convert Link<> to typed
Change-Id: I10b050dc4aae45e646761a82520caa96969bc511
Reviewed-on: https://gerrit.libreoffice.org/18700
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-09-20 06:37:36 +00:00
Noel Grandin
98236528da convert Link<> to typed
Change-Id: I5c4021c9cb3fdeace7f7d99d580dc7fe2f7c354a
2015-09-15 09:37:32 +02:00
Noel Grandin
371a535afb loplugin: defaultparams
Change-Id: I0538bbb2e121d8feeff03535cb327c957e03de1b
2015-08-14 11:11:07 +02:00
Andrea Gelmini
9f27e5b0e0 Fix typos
Change-Id: I52cbaad71560d73f5e24f3de3cd62b00d678dd6c
Reviewed-on: https://gerrit.libreoffice.org/17187
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2015-07-19 19:45:07 +00:00
Andrea Gelmini
799cc41b53 Fix typos
Change-Id: I70b03c152f63e48341dc5629a99b0eeab7b497c0
Reviewed-on: https://gerrit.libreoffice.org/16834
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2015-07-08 05:48:18 +00:00
Andrea Gelmini
465489d97a Fix typos
Change-Id: Id884946cae0687d0b71c967e236e58df17567884
Reviewed-on: https://gerrit.libreoffice.org/16707
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2015-07-03 09:43:46 +00:00
Andrea Gelmini
1a8915ef83 Fix typos
Change-Id: I1c5e4970d4e90bdea68a901294594104de5e189e
Reviewed-on: https://gerrit.libreoffice.org/16582
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2015-06-30 15:57:12 +00:00
Andrea Gelmini
ae150c6a54 Fix typos
Change-Id: Ibfa971952cd330ddf430e7e951c5c235d2ae6bd8
Reviewed-on: https://gerrit.libreoffice.org/16314
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
2015-06-18 11:44:56 +00:00
Stephan Bergmann
8e1ad96626 Some missing SolarMutexGuard around VclPtr acquire/release
At least OutputDevice::acquire/release use a plain unguarded int and ++, --, so
apparently rely on the SolarMutex being locked whenever they are called.  Fixed
those places that caused "make check" to fail for me when temporarily adding
DBG_TESTSOLARMUTEX() to OutputDevice::acquire/release.  (A recurring pattern is
that a class fails to ensure the SolarMutex is locked around the destruction of
non-null VclPtr members.)

Change-Id: I77cba6f3908f2de1b516ce28f1c3c43b3f57a9c5
2015-06-17 15:24:19 +02:00
Andrea Gelmini
814af9f1e5 Fix typos
Change-Id: Icfb885b72d51edc886851cf503c56fa12b8f559f
Reviewed-on: https://gerrit.libreoffice.org/16309
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2015-06-16 11:21:07 +00:00
Stephan Bergmann
a1a5588b1b loplugin:cstylecast: deal with remaining pointer casts
Change-Id: I4a72a60d621c65e63310ef70b991f9c86f00494d
2015-06-08 16:25:25 +02:00
Noel Grandin
82d68f9cbc convert COMMAND_ constants to scoped enum
Change-Id: I88e67f89dbbab0646e8f106dfeb32c6ee1bb0b95
Reviewed-on: https://gerrit.libreoffice.org/15671
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-05-11 12:17:42 +00:00
Noel Grandin
cce752b1ba convert SHOWDIALOG_ID constants to scoped enum
Change-Id: I58fffa7345f6b5050b8a1b3ac1022c630e64dbb4
Reviewed-on: https://gerrit.libreoffice.org/15651
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-05-08 06:50:24 +00:00
Stephan Bergmann
591c319227 More loplugin:simplifybool
Change-Id: If173ec26ed53cf99fd23f0930eaeefc595a05722
2015-04-27 15:30:56 +02:00
Noel Grandin
869aaf83bd convert SvtModuleOptions::EModule to scoped enum
Change-Id: I9665fc003cb3a44f4db857b24584fa3a70487259
2015-04-07 13:05:34 +02:00
Julien Nabet
d7f62705ab Typo: metod(s)->method(s)
Change-Id: Ie8e8c33bba30ae454c4a0cb54eb6613293a398e6
2015-04-01 21:15:57 +02:00
Stephan Bergmann
5d950b3afd Clean up C-style casts from pointers to void
Change-Id: Ide77480339e35a886f0d33c2a194244064c02488
2015-03-28 19:09:21 +01:00
Julien Nabet
2b347972fc Typos
Change-Id: I64995f15e8367412f345c6505668a1c560eef1ef
2015-03-03 22:07:23 +01:00
Julien Nabet
52fa2e97df Typos
Change-Id: I8d6e9b20c478e649e35eca16f39692a9ce42b3c5
2015-02-21 23:46:16 +01:00
Matthew Pottage
4f7a1f5b94 fdo#75757: Remove inheritance from std::vector
Deprecated comphelper/sequenceasvector.hxx.

Rewritten code using it. Using instead the functions containerToSequence and
sequenceToContainer, found in include/comphelper/sequence.hxx.

One class that inherits from it (in framework/inc/stdtypes.h), and
the code using that has been left.

Signed-off-by: Michael Stahl <mstahl@redhat.com>

Conflicts:
	writerfilter/source/dmapper/DomainMapper.cxx
	writerfilter/source/dmapper/TblStylePrHandler.hxx
	writerfilter/source/dmapper/WrapPolygonHandler.hxx

Change-Id: Ice61c94ffb052e389281aebb7cdf185134221061
2015-02-06 23:06:58 +01:00
Tor Lillqvist
d2ac4c3e68 'Ownership' is one word, as is 'relationship'
Change-Id: I45c441f68ed5f20cfc87e34e7bfb529a30952f81
2015-01-23 16:23:26 +02:00
Stephan Bergmann
b98352996c framework: Use appropriate OUString functions on string constants
Change-Id: I5da5cd3254102c742021b3e7b4e1f907ca897ca5
2014-12-18 14:12:22 +01:00
Andrea Gelmini
da40cac540 Fix common typos. No automatic tools. Handmade…
Change-Id: I1ab4e23b0539f8d39974787f226e57a21f96e959
Reviewed-on: https://gerrit.libreoffice.org/12164
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2014-11-12 11:04:11 +00:00
Noel Grandin
0371a63365 remove unnecessary 'using namespace rtl' declarations
It turns out that almost none of them were necessary.

Change-Id: I1311ed28409c682b57ea8d149bcbaf2c49133e83
Reviewed-on: https://gerrit.libreoffice.org/12133
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2014-10-29 11:28:54 +00:00
Stephan Bergmann
ad9498f8b8 More -Werror,-Wunused-private-field
...detected with a modified trunk Clang with

> Index: lib/Sema/SemaDeclCXX.cpp
> ===================================================================
> --- lib/Sema/SemaDeclCXX.cpp	(revision 219190)
> +++ lib/Sema/SemaDeclCXX.cpp	(working copy)
> @@ -1917,9 +1917,10 @@
>    const Type *T = FD.getType()->getBaseElementTypeUnsafe();
>    // FIXME: Destruction of ObjC lifetime types has side-effects.
>    if (const CXXRecordDecl *RD = T->getAsCXXRecordDecl())
> -    return !RD->isCompleteDefinition() ||
> -           !RD->hasTrivialDefaultConstructor() ||
> -           !RD->hasTrivialDestructor();
> +    return !RD->hasAttr<WarnUnusedAttr>() &&
> +           (!RD->isCompleteDefinition() ||
> +            !RD->hasTrivialDefaultConstructor() ||
> +            !RD->hasTrivialDestructor());
>    return false;
>  }
>
> @@ -3517,9 +3518,11 @@
>    bool addFieldInitializer(CXXCtorInitializer *Init) {
>      AllToInit.push_back(Init);
>
> +#if 0
>      // Check whether this initializer makes the field "used".
>      if (Init->getInit()->HasSideEffects(S.Context))
>        S.UnusedPrivateFields.remove(Init->getAnyMember());
> +#endif
>
>      return false;
>    }

to warn about members of SAL_WARN_UNUSED-annotated class types, and warn about
initializations with side effects (cf.
<http://lists.cs.uiuc.edu/pipermail/cfe-dev/2014-October/039602.html>
"-Wunused-private-field distracted by side effects").

Change-Id: I3f3181c4eb8180ca28e1fa3dffc9dbe1002c6628
2014-10-15 15:58:56 +02:00
Noel Grandin
1777c425fe loplugin: cstylecast
Change-Id: I4a8786f335b5f9a14116c546d32f1ff6cff99930
2014-10-02 07:37:19 +02:00
Noel Grandin
827c46e7d7 fdo#82577: Handle Window
Put the VCL Window class in the vcl namespace. Avoids clash with the X11
Window typedef.

Change-Id: Ib1beb7ab4ad75562a42aeb252732a073d25eff1a
2014-09-23 14:11:39 +03:00