Move osl::LibreOfficeKit stuff to comphelper for now
Let's see where it actually will be needed. Sal is a "picky" place for new API, even inside LIBO_INTERNAL_ONLY. Change-Id: Ia0c5ee8cfc6ee526c5ad34d2f8aab0b14b5f805b
This commit is contained in:
@@ -94,6 +94,7 @@ $(eval $(call gb_Library_add_exception_objects,comphelper,\
|
|||||||
comphelper/source/misc/interaction \
|
comphelper/source/misc/interaction \
|
||||||
comphelper/source/misc/listenernotification \
|
comphelper/source/misc/listenernotification \
|
||||||
comphelper/source/misc/logging \
|
comphelper/source/misc/logging \
|
||||||
|
comphelper/source/misc/lok \
|
||||||
comphelper/source/misc/mimeconfighelper \
|
comphelper/source/misc/mimeconfighelper \
|
||||||
comphelper/source/misc/namedvaluecollection \
|
comphelper/source/misc/namedvaluecollection \
|
||||||
comphelper/source/misc/numberedcollection \
|
comphelper/source/misc/numberedcollection \
|
||||||
|
34
comphelper/source/misc/lok.cxx
Normal file
34
comphelper/source/misc/lok.cxx
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||||
|
/*
|
||||||
|
* 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 <comphelper/lok.hxx>
|
||||||
|
|
||||||
|
namespace comphelper
|
||||||
|
{
|
||||||
|
|
||||||
|
namespace LibreOfficeKit
|
||||||
|
{
|
||||||
|
|
||||||
|
static bool bActive(false);
|
||||||
|
|
||||||
|
void setActive()
|
||||||
|
{
|
||||||
|
bActive = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool isActive()
|
||||||
|
{
|
||||||
|
return bActive;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace LibreOfficeKit
|
||||||
|
|
||||||
|
} // namespace comphelper
|
||||||
|
|
||||||
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
@@ -26,7 +26,6 @@
|
|||||||
#include "dispatchwatcher.hxx"
|
#include "dispatchwatcher.hxx"
|
||||||
#include <boost/scoped_ptr.hpp>
|
#include <boost/scoped_ptr.hpp>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <osl/lok.hxx>
|
|
||||||
#include <osl/process.h>
|
#include <osl/process.h>
|
||||||
#include <unotools/bootstrap.hxx>
|
#include <unotools/bootstrap.hxx>
|
||||||
#include <vcl/svapp.hxx>
|
#include <vcl/svapp.hxx>
|
||||||
@@ -40,6 +39,7 @@
|
|||||||
#include <unotools/moduleoptions.hxx>
|
#include <unotools/moduleoptions.hxx>
|
||||||
#include <rtl/bootstrap.hxx>
|
#include <rtl/bootstrap.hxx>
|
||||||
#include <rtl/strbuf.hxx>
|
#include <rtl/strbuf.hxx>
|
||||||
|
#include <comphelper/lok.hxx>
|
||||||
#include <comphelper/processfactory.hxx>
|
#include <comphelper/processfactory.hxx>
|
||||||
#include <cppuhelper/supportsservice.hxx>
|
#include <cppuhelper/supportsservice.hxx>
|
||||||
#include <osl/file.hxx>
|
#include <osl/file.hxx>
|
||||||
@@ -467,7 +467,7 @@ OfficeIPCThread::Status OfficeIPCThread::EnableOfficeIPCThread()
|
|||||||
// from LibreOfficeKit's lo_initialize() I am not completely sure, but that code, and this, is
|
// from LibreOfficeKit's lo_initialize() I am not completely sure, but that code, and this, is
|
||||||
// such horrible crack that I don't want to change it too much.
|
// such horrible crack that I don't want to change it too much.
|
||||||
|
|
||||||
if (osl::LibreOfficeKit::isActive())
|
if (comphelper::LibreOfficeKit::isActive())
|
||||||
{
|
{
|
||||||
// Setting nPipeMode to PIPEMODE_CREATED causes the trivial path to be taken below, starting
|
// Setting nPipeMode to PIPEMODE_CREATED causes the trivial path to be taken below, starting
|
||||||
// the listeing thread. (Which will immediately finish, see the execute() function, but what
|
// the listeing thread. (Which will immediately finish, see the execute() function, but what
|
||||||
@@ -707,7 +707,7 @@ void OfficeIPCThread::execute()
|
|||||||
#if HAVE_FEATURE_DESKTOP || defined(ANDROID)
|
#if HAVE_FEATURE_DESKTOP || defined(ANDROID)
|
||||||
|
|
||||||
#ifndef ANDROID
|
#ifndef ANDROID
|
||||||
if (osl::LibreOfficeKit::isActive())
|
if (comphelper::LibreOfficeKit::isActive())
|
||||||
return;
|
return;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@@ -22,13 +22,13 @@
|
|||||||
|
|
||||||
#include <tools/errinf.hxx>
|
#include <tools/errinf.hxx>
|
||||||
#include <osl/file.hxx>
|
#include <osl/file.hxx>
|
||||||
#include <osl/lok.hxx>
|
|
||||||
#include <osl/process.h>
|
#include <osl/process.h>
|
||||||
#include <osl/thread.h>
|
#include <osl/thread.h>
|
||||||
#include <rtl/strbuf.hxx>
|
#include <rtl/strbuf.hxx>
|
||||||
#include <rtl/bootstrap.hxx>
|
#include <rtl/bootstrap.hxx>
|
||||||
#include <cppuhelper/bootstrap.hxx>
|
#include <cppuhelper/bootstrap.hxx>
|
||||||
#include <comphelper/dispatchcommand.hxx>
|
#include <comphelper/dispatchcommand.hxx>
|
||||||
|
#include <comphelper/lok.hxx>
|
||||||
#include <comphelper/processfactory.hxx>
|
#include <comphelper/processfactory.hxx>
|
||||||
|
|
||||||
#include <com/sun/star/beans/XPropertySet.hpp>
|
#include <com/sun/star/beans/XPropertySet.hpp>
|
||||||
@@ -853,7 +853,7 @@ static int lo_initialize(LibreOfficeKit* pThis, const char* pAppPath)
|
|||||||
if (bInitialized)
|
if (bInitialized)
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
osl::LibreOfficeKit::setActive();
|
comphelper::LibreOfficeKit::setActive();
|
||||||
|
|
||||||
OUString aAppPath;
|
OUString aAppPath;
|
||||||
if (pAppPath)
|
if (pAppPath)
|
||||||
|
@@ -7,28 +7,24 @@
|
|||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef INCLUDED_OSL_LOK_HXX
|
#ifndef INCLUDED_COMPHELPER_LOK_HXX
|
||||||
#define INCLUDED_OSL_LOK_HXX
|
#define INCLUDED_COMPHELPER_LOK_HXX
|
||||||
|
|
||||||
#ifdef LIBO_INTERNAL_ONLY
|
#include <comphelper/comphelperdllapi.h>
|
||||||
|
|
||||||
#include <sal/saldllapi.h>
|
namespace comphelper
|
||||||
|
|
||||||
namespace osl
|
|
||||||
{
|
{
|
||||||
|
|
||||||
namespace LibreOfficeKit
|
namespace LibreOfficeKit
|
||||||
{
|
{
|
||||||
|
|
||||||
SAL_DLLPUBLIC void setActive();
|
COMPHELPER_DLLPUBLIC void setActive();
|
||||||
|
|
||||||
SAL_DLLPUBLIC bool isActive();
|
COMPHELPER_DLLPUBLIC bool isActive();
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // LIBO_INTERNAL_ONLY
|
#endif // INCLUDED_COMPHELPER_LOK_HXX
|
||||||
|
|
||||||
#endif // INCLUDED_OSL_LOK_HXX
|
|
||||||
|
|
||||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
@@ -17,7 +17,6 @@
|
|||||||
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <osl/lok.hxx>
|
|
||||||
#include <osl/time.h>
|
#include <osl/time.h>
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -46,22 +45,6 @@ public:
|
|||||||
|
|
||||||
static OGlobalTimer aGlobalTimer;
|
static OGlobalTimer aGlobalTimer;
|
||||||
|
|
||||||
namespace LibreOfficeKit
|
|
||||||
{
|
|
||||||
|
|
||||||
static bool bActive(false);
|
|
||||||
|
|
||||||
void setActive()
|
|
||||||
{
|
|
||||||
bActive = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool isActive()
|
|
||||||
{
|
|
||||||
return bActive;
|
|
||||||
}
|
|
||||||
|
|
||||||
} // namespace LibreOfficeKit
|
|
||||||
} // namespace osl
|
} // namespace osl
|
||||||
|
|
||||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
||||||
|
@@ -713,11 +713,6 @@ PRIVATE_textenc.1 { # LibreOffice 3.6
|
|||||||
_ZN3sal6detail7textenc37handleBadInputUnicodeToTextConversion*;
|
_ZN3sal6detail7textenc37handleBadInputUnicodeToTextConversion*;
|
||||||
};
|
};
|
||||||
|
|
||||||
PRIVATE_4.5 { # LibreOffice 4.5
|
|
||||||
_ZN3osl14LibreOfficeKit8isActive*;
|
|
||||||
_ZN3osl14LibreOfficeKit9setActive*;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Unique libstdc++ symbols:
|
# Unique libstdc++ symbols:
|
||||||
GLIBCXX_3.4 {
|
GLIBCXX_3.4 {
|
||||||
global:
|
global:
|
||||||
|
Reference in New Issue
Block a user