Commit Graph

407802 Commits

Author SHA1 Message Date
Jochen Nitschke
d237576df6 remove some unused forward declarations
and unused TransliterationModules include in editeng

Change-Id: I02e2d6acfde562a3e0cc8516eb16bb2ce8a810cc
Reviewed-on: https://gerrit.libreoffice.org/37556
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-05-14 13:33:46 +02:00
Arnaud Versini
d17c7a7ec8 accessibility: Remove useless locks.
Change-Id: I61bb14e33db1e32f0eb4c27cbb62e7f37006213f
Reviewed-on: https://gerrit.libreoffice.org/37342
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-05-14 13:33:03 +02:00
Maxim Monastirsky
180416ba64 Remove more %20 from style commands
And fix a typo found in H5/H6 commands in Writer's
style toolbar.

Change-Id: Ieb8f701d055870040010da66a9a108bbd089bc0a
2017-05-14 14:08:01 +03:00
Maxim Monastirsky
b769152dca tdf#96444 Shortcuts are saved with non-parsed URL
MenuBarManager overwrites the item URL with the parsed
version. This causes the keyboard shortcuts of style
commands to no longer be found on subsequent opening of
the menu, because they have spaces, which in the parsed
version were replaced with "%20".

Change-Id: I80b559203742922f70b7cec54b5a5ae57d3ef7dd
2017-05-14 14:07:17 +03:00
Maxim Monastirsky
b2bed3ef5e Revert "tdf#96444 Replace chr(20) with '%20' in style uno commands"
This reverts commit 939abe5a79.

This causes styles to not appear as having keyboard
shortcuts in Tools > Customize... > Keyboard, and style
buttons that were added using tdf#106681 to not have
their keyboard shortcuts in their tooltips.

Given that the original bug is a local problem in
MenuBarManager, I prefer to fix it there, rather than
put workarounds all over the place, including those ugly
"%20".

Change-Id: I797f463df2b37ab69f73f357ab9d120697e0ff33
2017-05-14 14:06:47 +03:00
Maxim Monastirsky
b91fb08fd6 tdf#106999 Feedback for style commands
The .uno:StyleApply command takes some arguments, which make
it possible to apply any style of any type. The problem is
that it doesn't provide toggle state to be used when placing
such commands on a toolbar or a menubar. The reason is that
sfx2, by design, can provide status updates only for the
.uno:StyleApply command as a whole, ignoring any arguments
that might be specified in the UI element description. This
behavior is even documented in the XDispatch idl.

wrt solution, changing the generic UI code to handle the
specifics of an individual command can never be a good idea.
The usual approach in such cases is to create separate
commands which will handle the status updates correctly. This
is however not possible in our case because styles can be
created by users, and we can't predict their names and create
separate commands for all of them (given that now it's easy to
add style commands to toolbars and menus - see tdf#106681).

One possible solution is to create a toolbar button controller
on top of .uno:StyleApply, which will be able to translate its
status update to a state compatible with the toolbar. The downside
is that it won't work when placing such command inside a menu, and
in general the menu code in framework doesn't provide any way to
control individual menu items, only a whole sub-menus via a
popup menu controller.

To fix the menu use-case too, this commit introduces a "proxy"
dispatch implementation, which can be used by MenuBarManager
in a transparent way, as if it was the "real" application-level
dispatcher. This means that the changes needed in MenuBarManager
are minimal and do not over-complicate the code, which is a good
thing (Alternatively, such dispatcher could be registered via
the dispatch interception mechanism, but it will add no gain,
given the current requirements, and just add more complexity).
And to make it easier to reuse the code, the new dispatcher
is also used for the toolbar solution.

Change-Id: Ia73b0fa70fd4d1d59360b255aa8fd19570b971ee
Reviewed-on: https://gerrit.libreoffice.org/37590
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
2017-05-14 11:08:35 +02:00
Maxim Monastirsky
c606bacc58 Allow destroying old MenuBarManager instances
... after dispatch interception change.

To reproduce:

1. Open the testdoc of tdf#102355
2. If not under gtk3 - Open several menus or sub menus.
3. Click the "Intercept" button.
4. Tools > Customize.. > Menus, make some change, click OK.

Expected that old MenuBarManagers (except the top level) are
destructed, and new ones are created. Actually the dtors of
MenuBarManagers from step 2 aren't called (but they will be
eventually called after closing Writer).

The reason we keep active status listening is mainly for
Unity's HUD (see my comment in MenuBarManager::Activate).
But it assumes that Activate was called for all menus,
which is done by GtkSalMenu at application startup,
but not after dispatch interception change. Should we fix
that, or maybe we can just kill this hack (along with
some related code in GtkSalMenu) anytime soon, given
that Unity is officially dead?

Change-Id: Ia1cb24391b393e31c98355dc91833c7511a17cda
Reviewed-on: https://gerrit.libreoffice.org/37589
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
2017-05-14 11:07:29 +02:00
Maxim Monastirsky
c7c445e93b Remove useless m_xContext.is() check
Similar to commit 3268092322 ("Fix the copy-paste").
The original code was using this to get URLTransformer,
but it was later switched to using m_xURLTransformer
in ca00697e3d ("CWS-TOOLING: integrate CWS oj18").

Change-Id: I05592915a651a9d8e0fc443f6adeb494704a99d8
Reviewed-on: https://gerrit.libreoffice.org/37588
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
2017-05-14 11:06:47 +02:00
Chris Sherlock
e7982510d2 osl: cleanup file_url.cxx
Change-Id: I636b0a7765be8e6e96e90ff5a004dc452048541a
2017-05-14 17:39:51 +10:00
Chris Sherlock
100895cf07 osl: osl_File.cxx unit test formatting cleanup
Change-Id: I0e0386834e9cf76cd3c606ae01175aec9cf7e4f1
2017-05-14 17:39:50 +10:00
Julien Nabet
68a1cb23ed fix gdi resource leak (svx/compressgraphicdialog)
Change-Id: Iea6e481384cee4d7e2ff6787c64d3048ba9c9d65
Reviewed-on: https://gerrit.libreoffice.org/37587
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-05-14 09:03:05 +02:00
Julien Nabet
11c4cc15fd fix gdi resource leak with unreleased virtual device
(copycat Markus https://cgit.freedesktop.org/libreoffice/core/commit/?id=289711c2a469bfbe06aef3b3870b65f9c788f56d)

Change-Id: I3974609559dd44257d7c3e9e9544348d622953f6
Reviewed-on: https://gerrit.libreoffice.org/37586
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-05-14 09:02:14 +02:00
Markus Mohrhard
b82c943928 handle test that apparently depends on our additional fonts
Change-Id: Ia2db679ee3e974da0f38d24257795d8c4b0ba1f9
Reviewed-on: https://gerrit.libreoffice.org/37560
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-05-14 01:05:26 +02:00
Julien Nabet
7e21f3d3fc tdf#107823: missing buttons in Presentation Minimizer
Regression from https://cgit.freedesktop.org/libreoffice/core/commit/?id=5d0e485e827057eee9fb2c997685690b710e7f34

Change-Id: I1864e7f7ac73fc13af82237f4f7d4dbaaa5733f5
Reviewed-on: https://gerrit.libreoffice.org/37584
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-05-14 00:52:32 +02:00
Markus Mohrhard
289711c2a4 fix gdi resource leak with unreleased virtual device
Change-Id: I1fd8c76a206cfc940e3d646e4025618785985e52
Reviewed-on: https://gerrit.libreoffice.org/37583
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-05-14 00:27:09 +02:00
Markus Mohrhard
c90510acfe add basic universal content test, tdf#107828
Change-Id: Ifb2a867cf2168a5ebf51d4a408d2e2a29032a764
Reviewed-on: https://gerrit.libreoffice.org/37580
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-05-13 23:34:16 +02:00
Markus Mohrhard
3e6e2f8db7 use empty document in orcus gnumeric import, tdf#107828
Change-Id: Ia7ee2de6f9b14a132a29c01f8d863889477c0a8d
Reviewed-on: https://gerrit.libreoffice.org/37579
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-05-13 23:32:16 +02:00
Markus Mohrhard
5e9178f765 import stream on the LibreOffice side, tdf#107827
This adds support for all LibreOffice content providers and non-ascii file names.

Change-Id: I0a0fd0ab0c78ef039679516e7a3e880929e8f725
Reviewed-on: https://gerrit.libreoffice.org/37578
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2017-05-13 23:25:19 +02:00
Arnaud Versini
c365ebc7ce accessibility: simplify and inline VCLXAccessibleList::clearItems
Change-Id: Ie32311850a0dc013e71e0456d7e6bfd8611e6e95
Reviewed-on: https://gerrit.libreoffice.org/37567
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-05-13 21:47:45 +02:00
Julien Nabet
c9275062ed tdf#101885: fix crash in AccFrameSelector
Deal with no parent case
0x00007ffff5e98240 in vcl::Window::GetChildCount() const ()
0  0x00007ffff5e98240 in vcl::Window::GetChildCount() const ()
1  0x00007ffff54f2d1f in svx::a11y::AccFrameSelector::getAccessibleIndexInParent() ()
See https://bugs.documentfoundation.org/attachment.cgi?id=127141

Change-Id: I795dc4c083d743466b5605d3dcc8f9fca8674c43
Reviewed-on: https://gerrit.libreoffice.org/37575
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-05-13 18:20:16 +02:00
Katarina Behrens
f7900c4860 Kill some code duplication, move shared code into private func
Change-Id: I4898f49c5bc6d68e73b283bc5b4abbfa0b000a40
Reviewed-on: https://gerrit.libreoffice.org/37541
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Eike Rathke <erack@redhat.com>
2017-05-13 13:43:11 +02:00
Julien Nabet
8aee79e352 tdf#107811: expert config, deal no parent case
bt part:
3  0x00007ffff73c7ee2 in __GI___assert_fail (assertion=0x7ffff7ba5107 "false", file=0x7ffff7ba4ef8 "/home/julien/lo/libreoffice/sal/rtl/strtmpl.cxx", line=1399,
    function=0x7ffff7ba6d00 <rtl_uString_newFromSubString::__PRETTY_FUNCTION__> "void rtl_uString_newFromSubString(rtl_uString**, const rtl_uString*, sal_Int32, sal_Int32)")
    at assert.c:101
4  0x00007ffff7b6a28b in rtl_uString_newFromSubString (ppThis=0x7ffffffef1b0, pFrom=0x55555e122230, beginIndex=1, count=-2)
    at /home/julien/lo/libreoffice/sal/rtl/strtmpl.cxx:1399
5  0x00007fffa6e69136 in rtl::OUString::copy (this=0x7ffffffef1f8, beginIndex=1, count=-2) at /home/julien/lo/libreoffice/include/rtl/ustring.hxx:2223
6  0x00007fffa6fed67b in CuiAboutConfigTabPage::InsertEntry (this=0x55555bda0b20, pEntry=0x55555e13eb40)
    at /home/julien/lo/libreoffice/cui/source/options/optaboutconfig.cxx:874
7  0x00007fffa6fed415 in CuiAboutConfigTabPage::SearchHdl_Impl (this=0x55555bda0b20) at /home/julien/lo/libreoffice/cui/source/options/optaboutconfig.cxx:848

Change-Id: Id9d1003a0e5e52abb878229e710e3fd4612789a1
Reviewed-on: https://gerrit.libreoffice.org/37568
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-05-13 12:48:28 +02:00
Miklos Vajna
c0968aa467 sw: fix gcc-4.8 build
After commit 2308bea5ba (sw: change
SwCursorShell::Pop() parameter from meaningless bool to enum,
2017-05-12).

Change-Id: I64ecdf3ea16383c3938b32acdf69a78a31938ae6
2017-05-13 09:58:12 +02:00
Chris Sherlock
26c83bbc00 osl: osl_File.cxx indent fixes
Change-Id: I4bd6fc88950e8e6fd5648f4a76201c135352e406
2017-05-13 14:06:19 +10:00
Chris Sherlock
b20d55706d osl: final cleanup of sal_File.cxx unit test
Change-Id: I00201c5456904a537e349fa5e30be223b744fc5e
2017-05-13 13:59:47 +10:00
Chris Sherlock
663c691aae osl: osl_File.cxx header cleanup
Change-Id: I9c76e2ef0ee7f28a51c0011ceb7e9e2f45f15ea7
2017-05-13 13:59:47 +10:00
Chris Sherlock
8e4f5da72d osl: osl_File.cxx qa test - remove osl namespace prefixes
Change-Id: Iacb82eff69ce5690ad0a054953835863c57dcce0
2017-05-13 13:59:47 +10:00
Chris Sherlock
e9006a937d osl: osl_File.cxx qa file cleanup
Change-Id: I4973cc0c8445f67cd2b3f6a9d158d6592c190447
2017-05-13 13:59:46 +10:00
Chris Sherlock
852e84e8ea osl: file test - space between C comment token and start of comment
Change-Id: Idf44ed079f04b16f2e8d718358567cfafecbe388
2017-05-13 13:59:46 +10:00
Chris Sherlock
f36ca24873 osl: remove commented code from file test
Change-Id: I85c41a6821e675874e9dae2ab4bfad35b7aebc59
2017-05-13 13:59:46 +10:00
Chris Sherlock
29b3857ce7 osl: remove extraneous comment cruft from test source
Change-Id: I1a7b5fc62359cd24593fadea1185db7e48c22961
2017-05-13 13:59:46 +10:00
Michael Stahl
2a95505762 sw: some old GCC apparently doesn't like that, let's try this
Change-Id: I1d6e74ae990faecfd3a28e0971ed6abe20bcef75
2017-05-13 00:44:14 +02:00
Michael Stahl
2308bea5ba sw: change SwCursorShell::Pop() parameter from meaningless bool to enum
Change-Id: Iadc660025e1501118cb0a659d92d42af924b1c6f
2017-05-12 23:41:27 +02:00
Johnny_M
566f6d4605 Translate German comments (rest of svx/)
Additionally to comments, this translates dbg. assertion strings.

Change-Id: Ia35b2a7336f2b5b30da36445274b1ea726f71f39
Reviewed-on: https://gerrit.libreoffice.org/37559
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2017-05-12 22:29:20 +02:00
Jens Carl
ac3fdadbe5 tdf#39468: Translate German comments/terms sw/source/filter/html/htmlfldw.cxx
Change-Id: I7e1e55632668f7947dbab7b2f00b19b76aecc0a3
Reviewed-on: https://gerrit.libreoffice.org/37526
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2017-05-12 22:06:29 +02:00
Christian Lohmaier
2e399f32e7 auto-turn with-ant-home into absolute path
Change-Id: I0b48f46256aa88486dd29b1d283fa8be1ef2dced
Reviewed-on: https://gerrit.libreoffice.org/37189
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
2017-05-12 22:03:11 +02:00
Jens Carl
b6dd4f355e tdf#39468: Translate German comments/terms in sw/source/filter/html/swhtml.cxx
The fourth set of translations.

Change-Id: I1d3c2a14d702a8b50130752fe653a783e1c54794
Reviewed-on: https://gerrit.libreoffice.org/37525
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2017-05-12 21:59:24 +02:00
Bernhard Widl
408a7e320d tdf#107795 fixed cursor position after inserting input field
Change-Id: I3c063c0393b524132e522914a7a9885c8a9c3b78
Reviewed-on: https://gerrit.libreoffice.org/37536
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
2017-05-12 21:21:46 +02:00
Michael Stahl
c9fb347642 sw: table-in-footnote: delete SwFootnoteFrame if it becomes empty
Crashed in a11y code with a SwFootnoteFrame that survived a JoinNode and
subsequent deletion of its reference-containing SwTextFrame and thus had
a stale "pRef" member; presumably the SwTableFrame needs to delete an
empty footnote frame like the SwTextFrame does from SwContentFrame::Cut(),
called from DelFrames(), called from CutImpl().

Change-Id: I5a30357ecd3bf474bfc4a5451de89beb245fb0ae
2017-05-12 21:18:59 +02:00
Michael Stahl
f6785b99a3 tdf#107568 sw: prevent moving/splitting of tables in footnotes
The problem here is that for a table in a footnote on page 42,
SwTabFrm::MakeAll() calls Split(), which first creates a
follow-table-frame and then reformats the last row of the table;
somehow the SwTextFrame id="4636" in that row doesn't fit and wants
to split and then move to the following page with that page's footnote
container as its parent.

So this doesn't work currently.

commit 971adcd9e1 tried to prevent just
the moving forward of the table itself, but the table can still be split;
if IsMoveable() returns false then that also prevents splitting the table.

Change-Id: I1977c65f97cb0f66dbe5b89d7ef7e2cd05125331
2017-05-12 21:18:58 +02:00
Jochen Nitschke
a280c61f7d update comments and remove TODO
TODO was addressed in commit 58c5a9de2a
when API version of importBiff12Formula was replaced with one using
ScAddress

Change-Id: I65629c80f8d5667c083602a87585d467d4c7dc60
Reviewed-on: https://gerrit.libreoffice.org/37555
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
2017-05-12 20:31:30 +02:00
Jochen Nitschke
05d3a1899e tdf#75280 replace uses of sal_uLong
those vars get their type from SvStream which uses sal_uInt64

Change-Id: Ia356699bb0f5e9787ae6f02e52e0b00cc2f817b1
Reviewed-on: https://gerrit.libreoffice.org/37547
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-05-12 19:34:14 +02:00
Vasily Melenchuk
cffc5a0466 tdf#100072 extra test for DOCX shape import with zero height
Corresponding bug is already fixed in tdf#107104. However created
tests do care only for width, but not for height, like we have in
this testcase.

Change-Id: I6f24e66e3c5e9289e158e0ca043ef01a3ea42880
Reviewed-on: https://gerrit.libreoffice.org/37538
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2017-05-12 18:09:13 +02:00
Eike Rathke
534746c99e Introduce and check FormulaTokenArray::mbFinalized to not add further tokens
Obviously after FormulaTokenArray::Assign() or the copy-ctor for that matter,
new tokens can not be added anymore to the shrunk code array. We don't do it,
but ensure that it isn't done in future..

Change-Id: Ibc0115f9f38e9745028a7459c61408c188783d03
2017-05-12 17:54:36 +02:00
Arul Michael
c882c60f54 tdf#106051 Notify listeners on top and bottom of split formula group
Change-Id: Icecb59a476f57cee0c04c3e21d60e6c7fa12f65a
Reviewed-on: https://gerrit.libreoffice.org/37011
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins <ci@libreoffice.org>
2017-05-12 17:16:29 +02:00
Eike Rathke
15074f1bfa Use ScTokenArray::AssignXMLString() and ScTokenArray stack object
Change-Id: I75477b3e9b5f71384084212b634faeaae3dddefa
2017-05-12 16:53:14 +02:00
Eike Rathke
bffe1113a3 Use ScTokenArray::AssignXMLString() and ScTokenArray stack object
Change-Id: Iac149278019932da7f269d85871c949f6b19f7c2
2017-05-12 16:50:41 +02:00
Caolán McNamara
858d1e0655 Resolves: tdf#107786 crash on null pointer access
Change-Id: I371d509e7ab6e7e0ef757e302d54ab75aa6c4c9b
2017-05-12 14:01:43 +01:00
Caolán McNamara
b5302844af ofz: use our own OString instead
Change-Id: I583a95aea0b29878bf4749a8cb2bb684da6da1e5
Reviewed-on: https://gerrit.libreoffice.org/37535
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-05-12 15:01:05 +02:00
Markus Mohrhard
eb8e28d80e fix build after 185ed3ddb8
Change-Id: I2c4f8df6009e407cb0da6fa1b7317a681647d89d
2017-05-12 14:40:47 +02:00