Commit Graph

226 Commits

Author SHA1 Message Date
Alexander Wilms
132d7941e0 Remove visual noise from jvmfwk
Change-Id: Ie9ad9478532b395bd6a2bddd54bbe0d10b1b5eb2
Reviewed-on: https://gerrit.libreoffice.org/8277
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-26 09:11:54 -06:00
Stephan Bergmann
f2529fc744 jvmfwk: sal_Bool -> bool
Change-Id: I35f302006cb9ef6e98a041dea811818b98c0e876
2014-02-18 12:17:37 +01:00
Stephan Bergmann
471cbb0522 bool improvements
Change-Id: I418611622b4b47ed5a4fa2ab99afb25371b186f6
2014-01-28 20:26:26 +01:00
Stephan Bergmann
65191cda81 bool improvements
Change-Id: I757e19313576d2c3d13af1cb720f182f0de91613
2014-01-27 10:47:32 +01:00
Stephan Bergmann
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
Stephan Bergmann
e7f7b1d09c bool improvements
Change-Id: Ic4572480d48e341c8fa611a3283efc351f530eb5
2014-01-21 13:24:30 +01:00
Noel Grandin
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
Noel Grandin
73342dbb82 remove unnecessary RTL_CONSTASCII_STRINGPARAM
A final pass through the code, converting code to use the new
OUString and OString methods that can detect string literals.

Change-Id: Ifa6382335e5650a1c67e52006b26354e0692c710
2013-11-22 08:07:19 +02:00
Noel Grandin
e52779d2f8 remove unnecessary use of OUString constructor
Change-Id: Ifb220af71857ddacd64e8204fb6d3e4aad8eef71
2013-11-11 11:21:26 +02:00
Michael Meeks
72b954df59 Avoid using gconftool. Atk provides a11y not Java on Unix.
cf. comment in framework header. Should have no impact on real
run-time Java a11y, which would be enabled later as-needed; only
on JRE selection. For extreme corner-cases, where your auto-selected
JRE has no a11y support either select another JRE in the UI or:

$ export JFW_PLUGIN_FORCE_ACCESSIBILITY=1

to override.

Change-Id: I59a6428e5a11664b75c29580cad76eb9500db45a
2013-10-30 11:09:55 +00:00
Stephan Bergmann
658e88c59d Improve debug output (and some clean up)
Change-Id: Ibce90b4eeab679d526f0e0b1e9a8ab3b14255622
2013-10-28 16:09:06 +01:00
Tor Lillqvist
01e1a2465e URE folder path fixes for the HAVE_FEATURE_MACOSX_MACLIKE_APP_STRUCTURE case
Change-Id: I5019cce2172db7b3ac74e25f5ea9dc62e9fd03f8
2013-10-05 21:10:42 +03:00
Luboš Luňák
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
Tor Lillqvist
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
Takeshi Abe
57931a7cf7 Mark as const
Change-Id: Ib78b25641ae20a3eb23545649f08b963e34c74ff
2013-07-29 17:39:30 +09:00
Stephan Bergmann
3af0114a29 Introduce O[U]String::toUInt32
...which has become necessary since bd60d41176
"Handle oveflow in O(U)String::toInt() functions" reduces values in the range
(SAL_MAX_INT32 .. SAL_MAX_UINT32] to zero, but some calls of toInt32(16) relied
on getting a correct (unsigned) value for the whole input range ["0" ..
"FFFFFFFF"] (see libreoffice-4-1 commit 9bf6c83367cedb7be81bf67f30d2147d26c7a8c3
"Revert overflow checks in O[U]String::toInt{32,64} again").

Audited all uses of toInt32/64 with non-decimal radix.  (There is still a TODO
comment in oox/source/helper/attributelist.cxx, and
stoc/source/typeconv/convert.cxx will still need some love and test code.)

Change-Id: Iadaca1c0e41dab553687d0ce41c20c10cd657a95
2013-06-13 17:08:36 +02:00
Philipp Riemer
e8eab43eeb cleanup whitespaces due to RTL_CONSTASCII_USTRINGPARAM removal
In e2e2cc6114 the method was removed
automatically leaving several line breaks etc. as visual noise.
2013-05-06 19:21:07 +02:00
Luboš Luňák
e2e2cc6114 remove usage of RTL_CONSTASCII_USTRINGPARAM
Mechanical removal of usage together with OUString ctor, done
by compiler plugin.

Change-Id: I554227f76df0dac620b1b46fca32516f78b462c5
2013-05-06 16:51:45 +02:00
Stephan Bergmann
2acc9da9e1 -Werror=unused-macros (MinGW, USE_ACCESSIBILITY_FILE)
...dead at least since c58b07c958 "#i20020#," if
not even since the beginning, 49614181e5 "#i20052#
plugin lib for java framework."

Change-Id: Ic0b35341cb8038ccfe0a2f4f5b758341b9ab13b9
2013-04-17 11:51:12 +02:00
Thomas Arnhold
435f5e30c9 fdo#60724 correct spelling
Change-Id: I7318a9f4f3410edf4dbe67bf08f31682fcb4edc7
2013-04-15 05:10:29 +02:00
Matúš Kukan
9fbe2f1b65 do not set soversion for private ure libraries
Change-Id: I2b2099d8fc00062f67c42e73c4b8a17a689db89d
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
2013-04-12 11:21:33 +02:00
Luboš Luňák
1946794ae0 mass removal of rtl:: prefixes for O(U)String*
Modules sal, salhelper, cppu, cppuhelper, codemaker (selectively) and odk
have kept them, in order not to break external API (the automatic using declaration
is LO-internal).

Change-Id: I588fc9e0c45b914f824f91c0376980621d730f09
2013-04-07 14:23:11 +02:00
Tor Lillqvist
b7525f1f1d Drop jvmaccess and jvmfwk when no SOLAR_JAVA
Just sprinkle #ifdef SOLAR_JAVA into the code instead.

In the source for jvmaccess and jvmfwk such ifdefs can be removed as
it isn't compiled unless SOLAR_JAVA.

Change-Id: Ia8614f8bd6d833582d3b79b5fb75f9153fa79606
2013-04-05 00:18:50 +03:00
David Tardon
769831b958 WaE: "UNX" is not defined
Change-Id: Ie1a98500fa4f3965872b3fc92a303df84556fd7a
2013-03-27 17:08:08 +01:00
Stephan Bergmann
aa753f01ba -Wunused-macros
Change-Id: Ifaa1637122d6f9cae1e29b77ac36ca5d1f220aed
2013-03-27 09:36:53 +01:00
Tor Lillqvist
55e95d1dcb warning: unknown log area 'jvmfwk' [loplugin]
This is not a warning that would stop an --enable-werror build, but still
worth fixing.

Change-Id: I6c47fd636f57f55cbe406f51e2f24e015924ce14
2013-03-22 08:57:58 +02:00
Thomas Arnhold
39d45390f4 removal of RTL_CONSTASCII_USTRINGPARAM for quoted OUStrings declarations
s/(OUString\s+[a-zA-Z_][A-Za-z0-9_]*\s*)\(\s*RTL_CONSTASCII_USTRINGPARAM\s*\((\s*"[^")]*?"\s*)\)\s*\)/$1\($2\)/gms

Change-Id: Iad20f242c80c4bdc69df17e2d7a69d58ea53654b
Reviewed-on: https://gerrit.libreoffice.org/2835
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
2013-03-19 10:48:30 +00:00
Thomas Arnhold
8b27d78b4a automated removal of RTL_CONSTASCII_USTRINGPARAM for quoted OUStrings
Done with a perl regex:

s/OUString\s*\(\s*RTL_CONSTASCII_USTRINGPARAM\s*\((\s*"[^")]*?"\s*)\)\s*\)/OUString\($1\)/gms

Change-Id: Idf28320817cdcbea6d0f7ec06a9bf51bd2c3b3ec
Reviewed-on: https://gerrit.libreoffice.org/2832
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
2013-03-19 09:00:26 +00:00
nccuong
a6b9173005 fdo#60148 Clean up warnings from the Clang compiler plugin
Change-Id: I08d755677c46c476710ecbd067ed9f7e2f54a671
loplugin: clean warnings: unused variables, incorrect indentation and log area.
Reviewed-on: https://gerrit.libreoffice.org/2544
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
2013-03-06 12:59:26 +00:00
Tor Lillqvist
616c6924f1 s/the the/the/
Change-Id: Iadacffaad832c6ff06757e8567e24f929f24a4c3
2013-02-22 09:58:19 +02:00
Julien Nabet
56f4d7dc9d Some cppcheck cleaning
Change-Id: I8609949377181f8edb30ac07b2791cfcd079fc7d
2013-02-12 21:24:25 +01:00
Stephan Bergmann
e5546342cb Let JavaVirtualMachine::getJavaVm start the VM it already found
Since b699519969 "Drop support for /etc/opt/ure
and ~/.ure from LibreOffice 4" there is no place any more where a plain URE will
store information about a selected JVM, so JavaVirtualMachine::getJavaVM will
go into an endless loop of jfw_startVM -> JFW_E_NO_SELECT ->
jfw_findAndSelectJRE -> jfw_startVM -> ...  The solution is to pass the JavaInfo
determined by jfw_findAndSelectJRE into the second invocation of jfw_startVM
(for which the parameter list of the latter needed to be changed), instead of
relying on jfw_findAndSelectJRE and jfw_startVM implicitly communicating that
information via user configuration files.

Change-Id: I5799f04c457e8a849c67ed827dc5e134c6563362
2012-12-18 12:47:39 +01:00
Stephan Bergmann
b699519969 Drop support for /etc/opt/ure and ~/.ure from LibreOffice 4
For one, /etc/opt/ure was probably never used by anyone anyway, so meant just
needless file-stats during startup.  For another, accidentally created
~/.ure/javasettings_*.xml that later became stale were noted to cause trouble,
so that source is now closed.

For this to work, jvmfwk needs to be silent now if it cannot read/write any
shared/user javasettings_*.xml.

Change-Id: I332b5ebb9549dc6ccf7c99c439d9a3b61aeb5829
2012-11-15 12:46:19 +01:00
Caolán McNamara
d00dc66996 loplugin: unused OStrings
Change-Id: I22916424fb97ba27ea6f4e540841a6c851fb8c88
2012-10-09 21:33:20 +01:00
Tor Lillqvist
3237a3772b Typo
Change-Id: I6ec48d3156f11c4ecb5f24a70a5c83603a86f834
2012-10-08 12:07:10 +03:00
Tor Lillqvist
ce3ac48c3a Fix for !SOLAR_JAVA
Change-Id: I43d8680304ef11f2b5f5e3edafcc6af6eca8d601
2012-10-08 11:40:48 +03:00
Tor Lillqvist
c56600dfbe Move the #ifndef DISABLE_DYNLOADING a bit earlier
Change-Id: I1777d6304b2ebb218c0f85c778f1a66d05c4f454
2012-10-07 10:43:07 +03:00
Tor Lillqvist
97593ae24a Handle lack of module loading/unloading API when DISABLE_DYNLOADING
There are basicically two classes of cases:

1) Where the code is for obscure historical reasons or what I see as
misguided "optimization" split into a more libraries than necessary,
and these then are loaded at run-time. Instead, just use direct
linking.

2) Where dynamic loading is part of the functionality offered to some
upper (scripting etc) layer, or where some system-specific non-LO
library is loaded dynamically, as it is not necessarily present on
end-user machines. Can't have such in the DISABLE_DYNLOADING case.

Change-Id: I9eceac5fb635245def2f4f3320821447bb7cd8c0
2012-10-07 07:59:15 +03:00
Noel Grandin
4faa36e42f sal_Bool->bool in jvmfwk
Change-Id: I8821bc7e4615421a710e6fdf913e646059dd5665
2012-10-04 21:29:33 +02:00
Arnaud Versini
36a2db3722 Replace usage of rtl_*Memory with equivalent from string.h
Change-Id: I50ffc10f007f03c3252ef0196b59b881429cc159
Reviewed-on: https://gerrit.libreoffice.org/734
Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
2012-10-01 18:48:05 +00:00
Stephan Bergmann
6dcb3d4ef4 Related fdo#51252: No more prereg, no more unopkg sync
Now that 5c47e5f63a "fdo#51252 Disable copying
share/prereg/bundled to avoid startup crashes" removed the use of share/prereg,
there is no longer need to generate it in the first place (by calling "unopkg
sync" at build or installation time), and so no need for the "unopkg sync" sub-
command, either.  This also allows to simplify some of the jvmfwk code that was
only there so that "unopkg sync" (which can require a JVM) can work in "hostile"
environments (during build and installation).

Change-Id: I52657384f4561bf27948ba4f0f88f4498e90987f
2012-08-10 16:03:28 +02:00
Stephan Bergmann
ce60a046d9 Globally unique symbols missing from some map files
...after gbuild'ification (they used to be added via solenv/bin/addsym.awk).
And sunjavaplugin.map is actually unused.

Change-Id: If6804cff8d01e268b84512d6c4b1edebde018cc0
2012-07-20 09:46:57 +02:00
Thomas Arnhold
1340890ccd simplify include guards
Change-Id: Id4210229b20a1d54b680ff1a2ccbcdd3684ecf5f
2012-07-14 05:44:15 +02:00
Michael Meeks
2c47c9989e re-base on ALv2 code. Includes:
cws mba34issues01: #i117709#: make sure that parent of error message box is visible
    Patch contributed by Mathias Bauer
    http://svn.apache.org/viewvc?view=revision&revision=1172346
    i#119036 - improve user experience of certification dialog - only shown once
    Patch contributed by Oliver-Rainer Wittmann
    http://svn.apache.org/viewvc?view=revision&revision=1299727
2012-07-13 21:38:47 +01:00
Takeshi Abe
eecb5ac9a4 removed useless forward declarations of class
Change-Id: I13cf52cc4e1cf8d5e2453d7ac4b68cc8c64cd011
2012-07-05 19:08:02 +09:00
Michael Meeks
69a51d2bb6 re-base on ALv2 code. 2012-06-26 11:33:02 +01:00
Michael Meeks
b9042fad7c re-base on ALv2 code.
Change-Id: I6c145e984c885c7e06caa1c27bfb354ea49ad9ce
2012-06-21 15:00:05 +01:00
Michael Meeks
b6db3e3acc re-base on ALv2 code.
Change-Id: Ice06e639213aeb6f7f23cbf4634947dd25613db1
2012-06-21 13:11:06 +01:00
Andras Timar
54e9a28390 typo: paramters, paramaters -> parameters
Change-Id: If58683331c50f2a95204e8e2dea11edbef3ccb63
2012-06-19 16:44:08 +02:00
Norbert Thiebaud
d79705d1df targeted string re-work
Change-Id: I31c752d044774cf4cec4aaab9bb2e43570d41953
2012-05-30 16:41:40 -05:00