[Libreoffice-commits] .: vcl/headless vcl/unx

Michael Meeks michael at kemper.freedesktop.org
Tue Feb 21 07:02:55 PST 2012


 vcl/headless/headlessinst.cxx         |    8 +++-----
 vcl/unx/generic/plugadapt/salplug.cxx |    4 ++--
 2 files changed, 5 insertions(+), 7 deletions(-)

New commits:
commit bc7b349ea262995d4599cda686d39af15a1e7aa6
Author: Riccardo Magliocchetti <riccardo.magliocchetti at gmail.com>
Date:   Tue Feb 21 14:55:10 2012 +0100

    headless: more work in vcl
    
    Provide HeadlessSalSystem::ShowNativeDialog() instead of having
    it if-zeroed.
    Then remove LIBO_HEADLESS ifdefery from unx/generic/plugadapt/salplug.cxx
    which we are not building anymore.

diff --git a/vcl/headless/headlessinst.cxx b/vcl/headless/headlessinst.cxx
index bde892f..439de86 100644
--- a/vcl/headless/headlessinst.cxx
+++ b/vcl/headless/headlessinst.cxx
@@ -49,22 +49,20 @@ HeadlessSalInstance::~HeadlessSalInstance()
 }
 
 class HeadlessSalSystem : public SvpSalSystem {
-#if 0
 public:
-    AndroidSalSystem() : SvpSalSystem() {}
-    virtual ~AndroidSalSystem() {}
+    HeadlessSalSystem() : SvpSalSystem() {}
+    virtual ~HeadlessSalSystem() {}
     virtual int ShowNativeDialog( const rtl::OUString& rTitle,
                                   const rtl::OUString& rMessage,
                                   const std::list< rtl::OUString >& rButtons,
                                   int nDefButton )
     {
         (void)rButtons; (void)nDefButton;
-        __android_log_print(ANDROID_LOG_INFO, "LibreOffice - dialog '%s': '%s'",
+        ::fprintf(stdout, "LibreOffice - dialog '%s': '%s'",
                             rtl::OUStringToOString(rTitle, RTL_TEXTENCODING_ASCII_US).getStr(),
                             rtl::OUStringToOString(rMessage, RTL_TEXTENCODING_ASCII_US).getStr());
         return 0;
     }
-#endif
 };
 
 SalSystem *HeadlessSalInstance::CreateSalSystem()
diff --git a/vcl/unx/generic/plugadapt/salplug.cxx b/vcl/unx/generic/plugadapt/salplug.cxx
index 1ce60de..1d9a5ba 100644
--- a/vcl/unx/generic/plugadapt/salplug.cxx
+++ b/vcl/unx/generic/plugadapt/salplug.cxx
@@ -53,7 +53,7 @@ static oslModule pCloseModule = NULL;
 static SalInstance* tryInstance( const OUString& rModuleBase, bool bForce = false )
 {
     SalInstance* pInst = NULL;
-#if !defined(ANDROID) || !defined(LIBO_HEADLESS)
+#if !defined(ANDROID)
     // Disable gtk3 plugin load except in experimental mode for now.
     if( !bForce &&
         rModuleBase.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "gtk3" ) ) &&
@@ -129,7 +129,7 @@ static SalInstance* tryInstance( const OUString& rModuleBase, bool bForce = fals
     return pInst;
 }
 
-#if !defined(ANDROID) || !defined(LIBO_HEADLESS)
+#if !defined(ANDROID)
 
 static DesktopType get_desktop_environment()
 {


More information about the Libreoffice-commits mailing list