Commit Graph

394 Commits

Author SHA1 Message Date
f400bdce03 fixincludeguards.sh: extensions
Change-Id: If652bce4cf7621795b084bcbc0aa4c46dd903878
2014-04-19 11:10:10 +02:00
5047891d04 typo: positon -> position 2014-04-14 12:33:12 +02:00
a6611be6bc Clean up function declarations and some unused functions
Change-Id: Ie81d270267b6c3c3620ade62eb393b28d995a654
2014-04-13 23:44:29 +02:00
5babf1b903 remove unnecessary scope qualifier from sal_Bool uses
i.e. convert "::sal_Bool" to "sal_Bool"

Change-Id: Ie5943aee4fee617bf2670655558927ed25b7e067
2014-04-03 13:54:02 +02:00
362d4f0cd4 Explicitly mark overriding destructors as "virtual"
It appears that the C++ standard allows overriding destructors to be marked
"override," but at least some MSVC versions complain about it, so at least make
sure such destructors are explicitly marked "virtual."

Change-Id: I0e1cafa7584fd16ebdce61f569eae2373a71b0a1
2014-04-01 19:22:54 +02:00
70cc2b191b First batch of adding SAL_OVERRRIDE to overriding function declarations
...mostly done with a rewriting Clang plugin, with just some manual tweaking
necessary to fix poor macro usage.

Change-Id: I71fa20213e86be10de332ece0aa273239df7b61a
2014-03-26 16:39:26 +01:00
42bfcce123 loplugin:passstringbyref
Change-Id: If08dab3956da5c0ee90d6a788f6f34a936e792d7
2014-03-19 08:40:48 +01:00
549c3b8119 Remove unused code
Change-Id: I1690f5b88b7bd04d336a45b1d745185285e13070
2014-03-17 12:56:42 +01:00
488817e3c4 No need for SAL_CALL here
Change-Id: I283c883bf49e33941de33b9e58d355f683c96ea3
2014-03-17 12:56:42 +01:00
15246c959a Remove visual noise from extensions
Change-Id: I0397d0d0e5343b7ed192a790664b068ac6955bd3
Reviewed-on: https://gerrit.libreoffice.org/8259
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2014-02-27 07:34:29 -06:00
5e21a413c7 cppuhelper: retrofit std::exception into overriding exception specs
Change-Id: I56e32131b7991ee9948ce46765632eb823d463b3
2014-02-26 18:22:20 +01:00
0ce0c369aa Remove unneccessary comments
Change-Id: I939160ae72fecbe3d4a60ce755730bd4c38497fb
Reviewed-on: https://gerrit.libreoffice.org/8182
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-23 03:38:49 +00:00
9377e44cf8 -Werror,-Wunused-function
Change-Id: Ic792930c291bae1cf18ffd65548908e910c69c45
2014-02-21 23:47:23 +01:00
11f9439a1c coverity#984089 Uninitialized scalar field
Change-Id: I299cfbe1f53af20f16dc02d3616d284a34da870d
2014-02-18 15:18:06 +00:00
627cf7e91a Do not use this in ctor
Change-Id: If2177d309626ef599c7c15f6195151dc0d0a8e30
2014-02-10 15:58:39 +01:00
ed0101dfaa auto_ptr -> scoped_ptr
Change-Id: I16d457d2981b7b3f60c150d362b8b51f6a2700fd
2014-02-10 15:58:38 +01:00
10be54247d Remove unnecessary abstract base class IByNameAccess
Change-Id: I55e8ff25f4a56a1666d49185236ee5cd5c4ed392
2014-02-10 15:58:38 +01:00
a29cdd540c bool improvements
Change-Id: If3402725c9cbff5df45043bd2ecd22dd6241c052
2014-01-28 20:26:28 +01:00
65191cda81 bool improvements
Change-Id: I757e19313576d2c3d13af1cb720f182f0de91613
2014-01-27 10:47:32 +01:00
e3133ae237 Let C++ inline functions return bool instead of sal_Bool
...to improve diagnosing misuses of boolean expressions in client code (cf.
compilerplugins/clang/implicitboolconversion.cxx).  This change should be
transparent to client code.

Missing overloads of insert() for bool have been added to OStringBuffer and
OUStringBuffer (which required dropping one !VALID_CONVERSION check that would
now pick that overload, but would be flagged by
compilerplugins/clang/pointertobool.cxx).

Change-Id: I2d64cd923b8f47bfaa31e753def6515c29a3f8c9
2014-01-23 18:43:53 +01:00
a3f32769fc Fix bogus mass-conversion equalsAsciiL -> startsWith
3af99e4d59d89c343965a928681a30f36b1007d2 "convert equalsAsciiL calls to
startsWith calls" should rather have converted to oprator ==.

Change-Id: Id4a8836c5d6d570e54661c40be7214632e202b21
2014-01-21 15:54:52 +01:00
fdf9406792 misuse of OUString::boolean on sal_uInt8 values
regression since 64b993e046f23baaacaff1572b7d2a816588b5ef

Change-Id: Ifc907a34430c36a64318fc42342e630e2b84ad13
2014-01-20 12:32:25 +00:00
62951cdd17 Introduce com.sun.star.frame.theGlobalEventBroadcaster singleton
...to supersede com.sun.star.frame.GlobalEventBroadcaster single-instance
service.

Change-Id: I74ecaadadb4c600d39979aa7c13b6389bed38fd7
2014-01-16 18:40:05 +01:00
9ed364774c Adapt all (non-extension, SharedLibrary) .components to environment="..."
Change-Id: I56f38bd786f3a026cb2908f28540dc9c4003af83
2013-12-17 11:06:00 +01:00
08fe82e59c Remove unnecessary use of OUString constructor in + expressions
Convert code like
  aFilename =  OUString::number(nFilePostfixCount) + OUString(".bmp");
to
  aFilename =  OUString::number(nFilePostfixCount) + ".bmp";

Change-Id: I03f513ad1c8ec8846b2afbdc67ab12525ed07e50
2013-12-17 11:49:03 +02:00
c5b7a5fd19 fix equalsAscii conversion. Noticed in fdo#72391
In commit 363cc397172f2b0a94d9c4dc44fc8d95072795a3
"convert equalsAsciiL calls to startWith calls where possible"
I incorrectly converted equalsAsciiL calls to startsWith calls.
This commit fixes those places to use the == OUString operator.

Change-Id: If76993baf73e3d8fb3bbcf6e8314e59fdc1207b6
2013-12-09 12:53:18 +02:00
5112f6a6c6 remove RTL_CONSTASCII_STRINGPARAM in OString constructor
Convert code like:
    OString aKeyName(RTL_CONSTASCII_STRINGPARAM("NDX"));
to:
    OString aKeyName("NDX");
which compiles down to the same code

Change-Id: I1780264cae4484fc78f0586b0750c09f2dce135f
2013-11-20 13:56:07 +02:00
3af99e4d59 convert equalsAsciiL calls to startsWith calls
Convert code like:
    aStr.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ActiveConnection" ) )
to
    aStr.startsWith( "ActiveConnection" )
which compiles down to the same machine code.

Change-Id: Id4b0c5e0f9afe716a468d3afc70374699848dc33
2013-11-20 10:07:31 +02:00
363cc39717 convert equalsAsciiL calls to startWith calls where possible
Simplify code like:
    aStr.equalsAsciiL( "%", 1 )
to
    aStr.startsWith( "%" )

Change-Id: Iee0e4e60b0ae6d567fa8f72db5d616fffbec3c00
2013-11-19 12:49:29 +02:00
ab5d1fbfb4 SAL_WARN_UNUSED com::sun::uno::Any
Change-Id: I9058044d13f696e07667dce706f6c311af6dbea0
2013-11-14 21:02:40 +01:00
456b6c886c -Werror,-Wunused-member-function
Change-Id: Ie738ad2c055b0e380a67c4d199e006fb99155e7c
2013-11-14 10:14:56 +01:00
d366c9b20e remove unnecessary sal_Unicode casts in various places
Change-Id: Ibf04062ca86ed866202d748c3b62a210d30ed6ec
2013-11-14 08:17:32 +02:00
22435a0777 remove unnecessary use of OUString constructor in EXTENSIONS module
Change-Id: Idf73eb831f52d4d74e6fbb6ea27f59ebbfd13a8c
2013-11-11 11:21:23 +02:00
d9da04ddc1 Some string clean-up
Change-Id: Ic046150605c599746ed3235c04bcbc981e18e589
2013-10-15 22:52:26 +02:00
4fa1fa931e Use OUString::replaceAll
Change-Id: Ide87f07a97a51d924947f7959016164b98ab43f9
2013-10-15 17:57:16 +02:00
7235d23267 fdo#54938: Adapt supportsService implementations to cppu::supportsService
Change-Id: I683c0d30c3286ed5d725d4eefe8b3977b82ee316
Reviewed-on: https://gerrit.libreoffice.org/6035
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Stephan Bergmann <sbergman@redhat.com>
2013-10-07 17:01:33 +00:00
38e9686b5b -Werror,-Wunused-variable
Change-Id: I57cb3540cb94dcf39252a87b56cba3856cba9c01
2013-10-02 18:40:15 +02:00
426f4f8136 valueOf() -> number()
Change-Id: I2832229b01de0cc5a725fd5fe1574a775d0bf12a
2013-08-21 15:39:22 +02:00
64b993e046 finish deprecation of O(U)String::valueOf()
Compiler plugin to replace with matching number(), boolean() or OUString ctor,
ran it, few manual tweaks, mark as really deprecated.

Change-Id: I4a79bdbcf4c460d21e73b635d2bd3725c22876b2
2013-08-21 15:10:35 +02:00
c6a7300974 Use subfolder names from <config_folders.h>
Change all instances of hardcoded "program", "share" etc subfolder names to
use those from <config_folders.h> instead. In normal builds, the end result
will not change.

Change-Id: I91c95cd8e482818be67307e889ae6df887763f53
2013-08-18 21:11:16 +03:00
7165b05968 i121946 - Use enums to identify WebDAV/HTTP methods
(cherry picked from commit 122e10cfd23b379b97e2d8ec002e7f0562ebd6f7)
Conflicts:
	extensions/source/update/feed/updatefeed.cxx
	offapi/com/sun/star/ucb/makefile.mk
	offapi/type_reference/typelibrary_history.txt
	offapi/type_reference/types.rdb
	ucb/source/ucp/webdav/DAVResourceAccess.cxx
	ucb/source/ucp/webdav/DAVResourceAccess.hxx
plus headerize.pl
(Would be an incompatible API CHANGE if we had not unpublished
XWebDAVCommandEnvironment with 78cca63070ae6cf82b45ec3bc75fafa2db31a7f2 "Revert
publishing of lots of UNO types.")

Change-Id: I153e394a194d0fcad29d3e3b27d5b24f7c259fc4
2013-08-15 16:55:24 +02:00
424300b69a i121945 - WebDAV ucp: return StringPair instead of NamedValue
Make css::ucb::XWebDAVCommandEnvironment::getUserRequestHeaders() return
a sequence of css:🫘:StringPair; this avoids all the any overhead,
and is much more simple and intuitive.

(cherry picked from commit 80199136d0d84b51b3d0529fb313b8f20f5cf851)
Conflicts:
	extensions/source/update/feed/updatefeed.cxx
	offapi/type_reference/typelibrary_history.txt
	offapi/type_reference/types.rdb
	ucb/source/ucp/webdav/DAVResourceAccess.cxx
(Would be an incompatible API CHANGE if we had not unpublished
XWebDAVCommandEnvironment with 78cca63070ae6cf82b45ec3bc75fafa2db31a7f2 "Revert
publishing of lots of UNO types.")

Change-Id: I1c5d0a0b225fe86aca6ba6d6c8903985005387c2
2013-08-15 16:55:24 +02:00
b2dfbdff7a i121944 - Implement inheritance in css::ucb::XWebDAVCommandEnvironment
It should be derived from css::ucb::XCommandEnvironment

(cherry picked from commit 817e11dccbfe3431f9cc0466051f4d154ce33e5e)
Conflicts:
	extensions/source/update/feed/updatefeed.cxx
	offapi/com/sun/star/ucb/XWebDAVCommandEnvironment.idl
	offapi/type_reference/typelibrary_history.txt
	offapi/type_reference/types.rdb
(Would be an incompatible API CHANGE if we had not unpublished
XWebDAVCommandEnvironment with 78cca63070ae6cf82b45ec3bc75fafa2db31a7f2 "Revert
publishing of lots of UNO types.")

Change-Id: Ie44bed44cce09c2423adab33c3790bdcb9be452d
2013-08-15 16:55:24 +02:00
f0b9a27703 make extensions XubString free
Change-Id: I0216d11ade872af889fc805e4c2a9241f7f230c5
2013-08-14 11:32:20 +01:00
f4a4fee523 loplugin:literalalternative
Change-Id: Ie2af2b013f95e8cdf7aab82498ce686dfa965cc8
2013-06-15 01:16:20 +02:00
c128736aad loplugin:unusedvariablecheck
Change-Id: I2202b5fcca4bf4c0a552d25c5c363209fcb6bd84
2013-06-15 00:57:19 +02:00
05e2d2bf03 fdo#64962 - ignore exceptions from checking with the update service.
Change-Id: If627b303f8710b915dcbdcb899454631f607e217
2013-06-05 13:03:22 +01:00
1f79707438 fdo#46808, Convert office::Quickstart service to new style
Service already existed, just needed an IDL file.

Change-Id: Ief5563e53c7331b65dd429079180c4eed2f2c071
2013-06-03 10:00:01 +02:00
1d1825db86 fdo#46808, Convert awt::UnoControlDialog to new style
Change-Id: I9a5256c8dbacda60167403b4e26900588943a9b2
2013-05-28 08:10:22 +02:00
e36f83d81c Revert "fdo#46808, Convert awt::UnoControlDialogModel to new style"
This reverts commit 6c61b20a8d4a6dcac28801cde82a211fb7e30654.  As discussed at
<http://lists.freedesktop.org/archives/libreoffice/2013-May/052449.html> "Re:
fdo#46808, Convert awt::UnoControlDialogModel to new style problem" why the odd
change in 2e2a4827ce6708f0e8677dba9cc92e1479a44086 "scripting: get
CreateUnoDialog() work again" appears to fix things again:

  The problem is that the implementation of the css.awt.UnoControlDialogModel
  involves UNO aggregation
  (IMPL_CREATE_INSTANCE_WITH_GEOMETRY(UnoControlDialogModel) in
  toolkit/soruce/helper/registerservices.cxx creating a
  OGeometryControlModel<UnoControlDialogModel> instance that aggregates a
  UnoControlDialogModel instance).  That means that queryInterface can return a
  reference to something that is technically a different object, and that's
  what's happening here, and explains why calling setPropertyValue in two
  different ways on what logically appears to be a single object can end up
  calling two different implementations (of two different physical objects).
  (UNO aggregation is known to be broken and should not be used.  Nevertheless,
  there's still code that does---code that is a horrible mess and hard to clean
  up.)

  That all this worked as intended in the past is just sheer luck, but any
  way of substantially touching it is asking for trouble.  I'm going to
  revert 6c61b20a8d4a6dcac28801cde82a211fb7e30654 again.

I wasn't able to revert without also reverting
be50ad28f5bbdaeff527f646481ce263843c2401 "fdo#46808, Convert
awt::XUnoControlDialog to new style," as the two were tightly dependant.  Also
reverts all the follow-up fixes cb4b6dde8fda2a5848e11063028bf44d72f85431
"-Werror,-Wuninitialized" (sans the const-ness fix in
UpdateHandler::insertControlModel), 697a007c61b9cabceb9767fad87cd5822b300452
"Fix exception specifications," 2ce6828bbbf6ba181bb2276adeec279e74151ef6 "fix
awt::UnoControlModelDialog crash," and 2e2a4827ce6708f0e8677dba9cc92e1479a44086
"scripting: get CreateUnoDialog() work again."

Conflicts:
	basctl/source/dlged/dlged.cxx
	filter/source/t602/t602filter.cxx
	xmlscript/test/imexp.cxx

Change-Id: I5d133468062f3ca36300db52fbd699be1ac72998
2013-05-25 11:45:47 +02:00