[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - desktop/source

2019-06-17 Thread Dennis Francis (via logerrit)
 desktop/source/app/app.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 92199ce4e544d17b4ceceefacf078c04996b57db
Author: Dennis Francis 
AuthorDate: Fri Jun 14 10:28:47 2019 +0530
Commit: Michael Stahl 
CommitDate: Mon Jun 17 14:32:59 2019 +0200

tdf#125691: use _exit() instead of exit()...

for ExitTimer which is used exclusively for
the case when  OOO_EXIT_POST_STARTUP is set, so
that there is no waiting around for ThreadPool's
threads to get joined.

Setting OOO_EXIT_POST_STARTUP already evades any
proper destruction of objects in the heap, so
using _exit() instead of exit() here does not
make things any worse w.r.t the purpose of this
env var.

Change-Id: Ib4a253d6e1a3fd8593e4a2115a51cf4c10344b3c
Reviewed-on: https://gerrit.libreoffice.org/74016
Tested-by: Jenkins
Reviewed-by: Miklos Vajna 
(cherry picked from commit d39846bfd16ad9873795149c370a95f42363bfd9)
Reviewed-on: https://gerrit.libreoffice.org/74154
Reviewed-by: Michael Stahl 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index 95b03bb2f46d..975108b5f052 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -1928,7 +1928,7 @@ class ExitTimer : public Timer
 }
 virtual void Invoke() override
 {
-exit(42);
+_exit(42);
 }
 };
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - desktop/source

2019-05-24 Thread Jan-Marek Glogowski (via logerrit)
 desktop/source/app/cmdlinehelp.cxx |   14 +-
 1 file changed, 9 insertions(+), 5 deletions(-)

New commits:
commit 0fe8175429ef0ee4cfeea718f99f375fb112496f
Author: Jan-Marek Glogowski 
AuthorDate: Thu May 23 12:58:39 2019 +
Commit: Michael Stahl 
CommitDate: Fri May 24 16:44:18 2019 +0200

Fix documented 'soffice --accept' parameter syntax

The parameter value for '--accept' is no UNO-Url, but uses a
similar syntax. This was wrongly changed in commit d78f29ab3f40
("tdf#100836 "Starting the LibreOffice Software With Parameters"
help update").

So this changes the parameter value back to {accept-string},
documents its syntax and adds some common examples.

Includes commit a82eed1e8ad3 ("Fix typo in help: 'urb' => 'urp")
(cherry picked from commit a82eed1e8ad3819fda34c26df035cd5472eeec5b)

Reviewed-on: https://gerrit.libreoffice.org/72859
Reviewed-by: Stephan Bergmann 
Tested-by: Jenkins
(cherry picked from commit a4066c770fec13af06a65a268c306a1f706f2cf0)

Change-Id: If8159b1d982c54e3dca6d27a1c400d2450ff2d1e
Reviewed-on: https://gerrit.libreoffice.org/72882
Reviewed-by: Michael Stahl 
Tested-by: Jenkins

diff --git a/desktop/source/app/cmdlinehelp.cxx 
b/desktop/source/app/cmdlinehelp.cxx
index 0dbbe41dd660..91cd00a6216e 100644
--- a/desktop/source/app/cmdlinehelp.cxx
+++ b/desktop/source/app/cmdlinehelp.cxx
@@ -96,12 +96,16 @@ namespace desktop
 "   --safe-mode Starts in a safe mode, i.e. starts temporarily 
with a\n"
 "   fresh user profile and helps to restore a 
broken\n"
 "   configuration.\n"
-"   --accept={UNO-URL}  Specifies an UNO-URL connect-string to create 
an UNO\n"
+"   --accept={connect-string}  Specifies a UNO connect-string to 
create a UNO\n"
 "   acceptor through which other programs can 
connect to\n"
-"   access the API. UNO-URL is string the such 
kind\n"
-"   
uno:connection-type,params;protocol-name,params;ObjectName.\n"
-"   --unaccept={UNO-URL} Closes an acceptor that was created with 
--accept. Use\n"
-"   --unaccept=all to close all open acceptors.\n"
+"   access the API. Note that API access allows 
execution\n"
+"   of arbitrary commands.\n"
+"   The syntax of the {connect-string} is:\n"
+" 
connection-type,params;protocol-name,params\n"
+"   e.g.  pipe,name={some name};urp\n"
+" or  socket,host=localhost,port=54321;urp\n"
+"   --unaccept={connect-string}  Closes an acceptor that was created 
with\n"
+"   --accept. Use --unaccept=all to close all 
acceptors.\n"
 "   --language={lang}   Uses specified language, if language is not 
selected\n"
 "   yet for UI. The lang is a tag of the language 
in IETF\n"
 "   language tag.\n\n"
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - desktop/source include/sfx2 sfx2/Library_sfx.mk sfx2/source solenv/clang-format

2019-05-03 Thread Stephan Bergmann (via logerrit)
 desktop/source/app/app.cxx|4 -
 include/sfx2/flatpak.hxx  |   34 ++
 include/sfx2/sfxhelp.hxx  |2 
 sfx2/Library_sfx.mk   |1 
 sfx2/source/appl/flatpak.cxx  |   99 ++
 sfx2/source/appl/sfxhelp.cxx  |   74 +--
 sfx2/source/view/viewsh.cxx   |   12 -
 solenv/clang-format/blacklist |2 
 8 files changed, 151 insertions(+), 77 deletions(-)

New commits:
commit d99e4864ef838093d47aa8f3c43403a082e26be2
Author: Stephan Bergmann 
AuthorDate: Tue Apr 30 10:38:38 2019 +0200
Commit: Michael Stahl 
CommitDate: Fri May 3 12:45:42 2019 +0200

Support "Preview in Web Browser" in Flatpak mode

...by storing the temporary HTML document in a location that can be 
accessed by
the browser running outside the Flatpak sandbox.  This reuses and extends 
the
mechanism already in place for the new HTML-based help in Flatpak mode (see
72b936d70b7eaa6d9f5f911b27e3c955382de967 "Enable --help=html for flatpak").

This fixes 

"“Preview in Web Browser” does not work in Flatpak version".

Change-Id: I5f73fd89139ffe6b8ab0dc501154b4f054a0ae5c
Reviewed-on: https://gerrit.libreoffice.org/71570
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 
(cherry picked from commit c61e7b9940cb30800d6f1000727f9cfd5de9fa5e)
Reviewed-on: https://gerrit.libreoffice.org/71717
Reviewed-by: Michael Stahl 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index 03448b5f1a41..95b03bb2f46d 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -108,7 +108,7 @@
 #include 
 #include 
 #include 
-#include 
+#include 
 #include 
 #include 
 #include 
@@ -1712,7 +1712,7 @@ int Desktop::doShutdown()
 
 // remove temp directory
 RemoveTemporaryDirectory();
-SfxHelp::removeFlatpakHelpTemporaryDirectory();
+flatpak::removeTemporaryHtmlDirectory();
 
 // flush evtl. configuration changes so that all config files in user
 // dir are written
diff --git a/include/sfx2/flatpak.hxx b/include/sfx2/flatpak.hxx
new file mode 100644
index ..cb5d758b51fe
--- /dev/null
+++ b/include/sfx2/flatpak.hxx
@@ -0,0 +1,34 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#ifndef INCLUDED_INCLUDE_SFX2_FLATPAK_HXX
+#define INCLUDED_INCLUDE_SFX2_FLATPAK_HXX
+
+#include 
+
+#include 
+#include 
+
+// Functionality related to the Flatpak version of LibreOffice.
+
+namespace flatpak {
+
+bool isFlatpak();
+
+// Must only be called with SolarMutex locked:
+bool createTemporaryHtmlDirectory(OUString ** url);
+
+// Must only be called with SolarMutex locked:
+SFX2_DLLPUBLIC void removeTemporaryHtmlDirectory();
+
+}
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s 
cinkeys+=0=break: */
diff --git a/include/sfx2/sfxhelp.hxx b/include/sfx2/sfxhelp.hxx
index d7afeb2b9af0..99ca1a062f04 100644
--- a/include/sfx2/sfxhelp.hxx
+++ b/include/sfx2/sfxhelp.hxx
@@ -53,8 +53,6 @@ public:
 static OUString GetCurrentModuleIdentifier();
 // Check for built-in help
 static bool IsHelpInstalled();
-
-static void removeFlatpakHelpTemporaryDirectory();
 };
 
 #endif // INCLUDED_SFX2_SFXHELP_HXX
diff --git a/sfx2/Library_sfx.mk b/sfx2/Library_sfx.mk
index 97f6f9706e76..750f3b354c73 100644
--- a/sfx2/Library_sfx.mk
+++ b/sfx2/Library_sfx.mk
@@ -94,6 +94,7 @@ $(eval $(call gb_Library_add_exception_objects,sfx,\
 sfx2/source/appl/childwin \
 sfx2/source/appl/childwinimpl \
 sfx2/source/appl/fileobj \
+sfx2/source/appl/flatpak \
 sfx2/source/appl/fwkhelper \
 sfx2/source/appl/helpdispatch \
 sfx2/source/appl/helpinterceptor \
diff --git a/sfx2/source/appl/flatpak.cxx b/sfx2/source/appl/flatpak.cxx
new file mode 100644
index ..14411dafc5d0
--- /dev/null
+++ b/sfx2/source/appl/flatpak.cxx
@@ -0,0 +1,99 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; 
fill-column: 100 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include 
+
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+bool flatpak::isFlatpak() {
+static auto const flatpak = [] { return std::getenv("LIBO_FLATPAK") != 
nullptr; }();
+return flatpak;
+}
+

[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - desktop/source

2019-01-28 Thread Libreoffice Gerrit user
 desktop/source/lib/init.cxx |7 +--
 1 file changed, 5 insertions(+), 2 deletions(-)

New commits:
commit ad322cd74e9540dc37dff8f599ade60c4d2bf9a2
Author: Michael Meeks 
AuthorDate: Fri Jan 25 17:47:15 2019 +
Commit: Caolán McNamara 
CommitDate: Mon Jan 28 22:14:25 2019 +0100

lok: don't crash in simple LOK use-case with no callback.

Change-Id: I7bceba10f002ad5751e3d810f9a9767ad2e875bc
Reviewed-on: https://gerrit.libreoffice.org/66924
Tested-by: Jenkins
Reviewed-by: Michael Meeks 
(cherry picked from commit 175274a6bca20451ccd6b5574e118265449f7642)
Reviewed-on: https://gerrit.libreoffice.org/66929
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index a7ce8182ebd1..4964859eb664 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -1522,8 +1522,11 @@ static LibreOfficeKitDocument* 
lo_documentLoadWithOptions(LibreOfficeKit* pThis,
 }
 
 LibLODocument_Impl* pDocument = new LibLODocument_Impl(xComponent);
-int nState = doc_getSignatureState(pDocument);
-pLib->mpCallback(LOK_CALLBACK_SIGNATURE_STATUS, 
OString::number(nState).getStr(), pLib->mpCallbackData);
+if (pLib->mpCallback)
+{
+int nState = doc_getSignatureState(pDocument);
+pLib->mpCallback(LOK_CALLBACK_SIGNATURE_STATUS, 
OString::number(nState).getStr(), pLib->mpCallbackData);
+}
 return pDocument;
 }
 catch (const uno::Exception& exception)
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - desktop/source filter/source include/sfx2 include/vcl sfx2/source vcl/source

2019-01-11 Thread Libreoffice Gerrit user
 desktop/source/deployment/gui/dp_gui_dialog2.cxx |   29 --
 desktop/source/deployment/gui/dp_gui_dialog2.hxx |   13 --
 filter/source/xsltdialog/xmlfiltersettingsdialog.cxx |   26 -
 filter/source/xsltdialog/xmlfiltersettingsdialog.hxx |6 ++-
 include/sfx2/sfxhelp.hxx |2 -
 include/vcl/waitobj.hxx  |   15 +++
 sfx2/source/appl/sfxhelp.cxx |   37 +++
 vcl/source/window/dialog.cxx |   25 
 8 files changed, 59 insertions(+), 94 deletions(-)

New commits:
commit 3a4a90e6e59e16e2ea0883caba87e114a07642f3
Author: Caolán McNamara 
AuthorDate: Thu Jan 10 10:44:31 2019 +
Commit: Caolán McNamara 
CommitDate: Fri Jan 11 14:09:42 2019 +0100

Resolves: tdf#122404 unlock just the toplevels that were locked

push what toplevels got locked to just unlock those ones. otherwise the just
dismissed toplevel may still be present in the Application toplevel list.

merge all the similar examples of this.

Change-Id: I77c0d55d1e4b3bcc3b8d88fef00ba289edd1e831
Reviewed-on: https://gerrit.libreoffice.org/66078
Tested-by: Jenkins
Tested-by: Xisco Faulí 
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.cxx 
b/desktop/source/deployment/gui/dp_gui_dialog2.cxx
index 62e2e301bfc4..765ac22a49f6 100644
--- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx
+++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx
@@ -340,7 +340,6 @@ DialogHelper::DialogHelper(const uno::Reference< 
uno::XComponentContext > 
Dialog *pWindow)
 : m_xVCLWindow(pWindow)
 , m_nEventID(nullptr)
-, m_nBusy(0)
 {
 m_xContext = xContext;
 }
@@ -462,34 +461,6 @@ void DialogHelper::PostUserEvent( const Link& 
rLink, void* pCaller )
 m_nEventID = Application::PostUserEvent( rLink, pCaller, 
true/*bReferenceLink*/ );
 }
 
-void DialogHelper::incBusy()
-{
-++m_nBusy;
-// lock any toplevel windows from being closed until busy is over
-// ensure any dialogs are reset before entering
-vcl::Window *xTopWin = Application::GetFirstTopLevelWindow();
-while (xTopWin)
-{
-if (xTopWin != m_xVCLWindow)
-xTopWin->IncModalCount();
-xTopWin = Application::GetNextTopLevelWindow(xTopWin);
-}
-}
-
-void DialogHelper::decBusy()
-{
---m_nBusy;
-// unlock any toplevel windows from being closed until busy is over
-// ensure any dialogs are reset before entering
-vcl::Window *xTopWin = Application::GetFirstTopLevelWindow();
-while (xTopWin)
-{
-if (xTopWin != m_xVCLWindow)
-xTopWin->DecModalCount();
-xTopWin = Application::GetNextTopLevelWindow(xTopWin);
-}
-}
-
 // ExtMgrDialog
 ExtMgrDialog::ExtMgrDialog(vcl::Window *pParent, TheExtensionManager 
*pManager, Dialog::InitFlag eFlag)
 : ModelessDialog(pParent, "ExtensionManagerDialog", 
"desktop/ui/extensionmanager.ui", eFlag)
diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.hxx 
b/desktop/source/deployment/gui/dp_gui_dialog2.hxx
index dd0dc8bb8160..a2d88c0f458e 100644
--- a/desktop/source/deployment/gui/dp_gui_dialog2.hxx
+++ b/desktop/source/deployment/gui/dp_gui_dialog2.hxx
@@ -29,6 +29,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 
 #include 
@@ -47,6 +48,9 @@
 #include 
 #include 
 
+#include 
+#include 
+
 namespace dp_gui {
 
 
@@ -60,7 +64,7 @@ class DialogHelper
 css::uno::Reference< css::uno::XComponentContext > m_xContext;
 VclPtr  m_xVCLWindow;
 ImplSVEvent *   m_nEventID;
-int m_nBusy;
+TopLevelWindowLocker m_aBusy;
 
 public:
 DialogHelper( const css::uno::Reference< 
css::uno::XComponentContext > &,
@@ -91,14 +95,13 @@ public:
const char* pResID,
bool  );
 
-voidincBusy();
-voiddecBusy();
-boolisBusy() const { return m_nBusy > 0; }
+voidincBusy() { m_aBusy.incBusy(m_xVCLWindow); }
+voiddecBusy() { m_aBusy.decBusy(); }
+boolisBusy() const { return m_aBusy.isBusy(); }
 boolinstallExtensionWarn(const OUString );
 boolinstallForAllUsers(bool );
 };
 
-
 class ExtMgrDialog : public ModelessDialog,
  public DialogHelper
 {
diff --git a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx 
b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
index a65b5824664b..3aef69274ba8 100644
--- a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
@@ -132,32 +132,6 @@ void XMLFilterSettingsDialog::dispose()
 ModelessDialog::dispose();
 }
 
-void 

[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - desktop/source

2018-12-27 Thread Libreoffice Gerrit user
 desktop/source/deployment/gui/dp_gui_theextmgr.cxx |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 14f827ee132e06fbd4131df2ba4141715db4caab
Author: Caolán McNamara 
AuthorDate: Sun Dec 23 20:05:14 2018 +
Commit: Adolfo Jayme Barrientos 
CommitDate: Fri Dec 28 07:36:07 2018 +0100

tdf#122269 don't prompt to restart if we're exiting the application anyway

Change-Id: I6272ae92b7e948680fb7241c387eb205adbbea01
Reviewed-on: https://gerrit.libreoffice.org/65589
Tested-by: Jenkins
Reviewed-by: Xisco Faulí 
Tested-by: Xisco Faulí 
Reviewed-by: Adolfo Jayme Barrientos 

diff --git a/desktop/source/deployment/gui/dp_gui_theextmgr.cxx 
b/desktop/source/deployment/gui/dp_gui_theextmgr.cxx
index 5a1a2528955c..f64538a3c64b 100644
--- a/desktop/source/deployment/gui/dp_gui_theextmgr.cxx
+++ b/desktop/source/deployment/gui/dp_gui_theextmgr.cxx
@@ -442,6 +442,7 @@ void TheExtensionManager::queryTermination( 
::lang::EventObject const & )
 }
 else
 {
+clearModified();
 if ( m_pExtMgrDialog )
 m_pExtMgrDialog->Close();
 if ( m_pUpdReqDialog )
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - desktop/source distro-configs/LibreOfficeFlatpak.conf include/sfx2 sfx2/source solenv/flatpak-manifest.in

2018-12-20 Thread Libreoffice Gerrit user
 desktop/source/app/app.cxx |2 
 distro-configs/LibreOfficeFlatpak.conf |1 
 include/sfx2/sfxhelp.hxx   |2 
 sfx2/source/appl/sfxhelp.cxx   |  258 -
 solenv/flatpak-manifest.in |8 +
 5 files changed, 268 insertions(+), 3 deletions(-)

New commits:
commit e03924c5d8a817e0ea5b56b96185aca152836dc9
Author: Stephan Bergmann 
AuthorDate: Wed Dec 12 17:13:03 2018 +0100
Commit: Caolán McNamara 
CommitDate: Thu Dec 20 22:32:02 2018 +0100

Enable --help=html for flatpak

To not increase the size of the main org.libreoffice.LibreOffice app 
further,
the plan was to realize this as an org.libreoffice.LibreOffice.Help 
extension.
Ideally, this would be a localized extension, so that, by default, only a
relevant subset of the extension would be downloaded and installed.  (But 
see
below.)

There are multiple technical problems, as discussed at  "Add
integrated LibreOffice Help offline":

* LO can't pass a file URL with query part to xdg-open, so uses a temporary
  wrapper .html file that redirects to the target URL.  But for the flatpak 
case
  this wrapper can't be in /tmp (which isn't visible from outside the 
flatpak
  sandbox), but is instead stored in a new temp dir under $XDG_CACHE_HOME 
(which
  is always set for flatpaks and /is/ visible form the outside) that is
  removed on LO exit.

* The file URL stored in the temp file must be rewritten from the internal 
path
  (/app/libreoffice/help/...) to the path as seen outside the flatpak 
sandbox.
  While the path for the org.libreoffice.LibreOffice /app is stored in
  /.flatpak-info, the external path for the org.libreoffice.LibreOffice.Help
  extension is different and not stored there.  So use a hack trying to
  construct that path from what information is available in /.flatpak-info.

* But the help content consists of locale-specific and shared files, and 
those
  reference each other with relative links.  But a localized flatpak 
extension
  cannot contain shared files, it can only contain per-language sub-dirs.  
And
  if the shared help files were kept out of the extension, as part of the 
app
  itself, the relative paths among these files inside the flatpak sandbox 
would
  differ from those outside of it, so would be broken when viewing the 
content
  in the external browser.  A solution would either (a) need to somehow 
rewrite
  the content of all the help files being served from LO to the external
  browser, or (b) replicate the shared help files in all the extension's 
per-
  language sub-dirs (and if some localization uses en-US content as a 
fallback
  for only part of its translated content, e.g., in the case of media files,
  would need to also replicate that en-US content), or (c) use a 
non-localized
  extension that always contains the content for all localizations.

For now, I chose the third approach.  This makes the
org.libreoffice.LibreOffice.Help extension relatively large (the current
/app/libreoffice/help tree has a size of ca. 100MB), so that I decided to 
not
have it downloaded and installed automatically ("no-autodownload": true in
solenv/flatpak-manifest.in).  (I checked with Flatpak 1.0.6 that if the
extension should be changed to a localized one with the same name in the 
future,
updating from an older version would work.  If the old extension was not
installed, just the relevant localizations of the new version will be 
downloaded
and installed.  If the old extension was installed, the full set of
localizations of the new version will be downloaded and installed.)

(As also mentioned at 
:  "A second, minor, nuisance is that, for
security reasons, an `xdg-open file:///...html` call from a flatpak leads 
to an
intermediate popup dialog letting the user chose which application to use to
open the URI, while e.g. an `xdg-open http:///...html` is allowed to go 
directly
to the user's preferred browser.  So accessing help content from LO flatpak
would present that popup dialog first, forcing the user to select a browser 
to
proceed.")

Reviewed-on: https://gerrit.libreoffice.org/65451
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 
(cherry picked from commit 72b936d70b7eaa6d9f5f911b27e3c955382de967)

Change-Id: I35f5a23947dd551dc1b9bff1dd2abd6710073b5f
Reviewed-on: https://gerrit.libreoffice.org/65482
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index b74defb1f640..03448b5f1a41 100644

[Libreoffice-commits] core.git: Branch 'libreoffice-6-2' - desktop/source

2018-11-28 Thread Libreoffice Gerrit user
 desktop/source/deployment/gui/dp_gui_dialog2.cxx |   84 ++-
 desktop/source/deployment/gui/dp_gui_dialog2.hxx |   23 +++---
 2 files changed, 78 insertions(+), 29 deletions(-)

New commits:
commit f2a39e1d9184b7cda32b713b699d19ac3d023849
Author: Caolán McNamara 
AuthorDate: Wed Nov 28 11:12:55 2018 +
Commit: Caolán McNamara 
CommitDate: Wed Nov 28 15:09:55 2018 +0100

Resolves: tdf#121746 block toplevels from closing...

while the extension manager is querying via a dialog. Reuse
the isBusy for this.

Change-Id: I97572404ae296e87fd44711bf1e978bd5bad6280
Reviewed-on: https://gerrit.libreoffice.org/64161
Tested-by: Jenkins
Reviewed-by: Caolán McNamara 
Tested-by: Caolán McNamara 

diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.cxx 
b/desktop/source/deployment/gui/dp_gui_dialog2.cxx
index b36f18d8f5dc..62e2e301bfc4 100644
--- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx
+++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx
@@ -336,16 +336,15 @@ void ExtBoxWithBtns_Impl::enableButtons( bool bEnable )
 
 // DialogHelper
 
-DialogHelper::DialogHelper( const uno::Reference< uno::XComponentContext > 
,
-Dialog *pWindow ) :
-m_pVCLWindow( pWindow ),
-m_nEventID(   nullptr ),
-m_bIsBusy(false )
+DialogHelper::DialogHelper(const uno::Reference< uno::XComponentContext > 
,
+   Dialog *pWindow)
+: m_xVCLWindow(pWindow)
+, m_nEventID(nullptr)
+, m_nBusy(0)
 {
 m_xContext = xContext;
 }
 
-
 DialogHelper::~DialogHelper()
 {
 if ( m_nEventID )
@@ -366,17 +365,21 @@ bool DialogHelper::continueOnSharedExtension( const 
uno::Reference< deployment::
 if ( !bHadWarning && IsSharedPkgMgr( xPackage ) )
 {
 const SolarMutexGuard guard;
+incBusy();
 std::unique_ptr 
xBox(Application::CreateMessageDialog(pParent,
   VclMessageType::Warning, 
VclButtonsType::OkCancel, DpResId(pResID)));
 bHadWarning = true;
 
-return RET_OK == xBox->run();
+bool bRet = RET_OK == xBox->run();
+xBox.reset();
+decBusy();
+return bRet;
 }
 else
 return true;
 }
 
-void DialogHelper::openWebBrowser( const OUString & sURL, const OUString 
 ) const
+void DialogHelper::openWebBrowser(const OUString& sURL, const OUString& sTitle)
 {
 if ( sURL.isEmpty() ) // Nothing to do, when the URL is empty
 return;
@@ -393,29 +396,35 @@ void DialogHelper::openWebBrowser( const OUString & sURL, 
const OUString 
 uno::Any exc( ::cppu::getCaughtException() );
 OUString msg( ::comphelper::anyToString( exc ) );
 const SolarMutexGuard guard;
+incBusy();
 std::unique_ptr 
xErrorBox(Application::CreateMessageDialog(getFrameWeld(),

VclMessageType::Warning, VclButtonsType::Ok, msg));
 xErrorBox->set_title(sTitle);
 xErrorBox->run();
+xErrorBox.reset();
+decBusy();
 }
 }
 
-
-bool DialogHelper::installExtensionWarn( const OUString  ) const
+bool DialogHelper::installExtensionWarn(const OUString )
 {
 const SolarMutexGuard guard;
 
 // Check if extension installation is disabled in the expert configurations
 if 
(officecfg::Office::ExtensionManager::ExtensionSecurity::DisableExtensionInstallation::get())
 {
+incBusy();
 std::unique_ptr 
xWarnBox(Application::CreateMessageDialog(getFrameWeld(),
   VclMessageType::Warning, 
VclButtonsType::Ok,
   
DpResId(RID_STR_WARNING_INSTALL_EXTENSION_DISABLED)));
 xWarnBox->run();
+xWarnBox.reset();
+decBusy();
 
 return false;
 }
 
+incBusy();
 std::unique_ptr 
xInfoBox(Application::CreateMessageDialog(getFrameWeld(),
   VclMessageType::Warning, 
VclButtonsType::OkCancel,
   
DpResId(RID_STR_WARNING_INSTALL_EXTENSION)));
@@ -423,15 +432,21 @@ bool DialogHelper::installExtensionWarn( const OUString 
 ) const
 sText = sText.replaceAll("%NAME", rExtensionName);
 xInfoBox->set_primary_text(sText);
 
-return (RET_OK == xInfoBox->run());
+bool bRet = RET_OK == xInfoBox->run();
+xInfoBox.reset();
+decBusy();
+return bRet;
 }
 
-bool DialogHelper::installForAllUsers( bool  ) const
+bool DialogHelper::installForAllUsers(bool )
 {
 const SolarMutexGuard guard;
+incBusy();
 std::unique_ptr 
xBuilder(Application::CreateBuilder(getFrameWeld(), 
"desktop/ui/installforalldialog.ui"));
 std::unique_ptr 
xQuery(xBuilder->weld_message_dialog("InstallForAllDialog"));
 short nRet = xQuery->run();
+xQuery.reset();
+decBusy();
 if (nRet ==