[Libreoffice-commits] core.git: config_host/config_features.h.in configure.ac desktop/source sfx2/source

Tor Lillqvist tml at iki.fi
Thu Mar 28 02:50:03 PDT 2013


 config_host/config_features.h.in                    |   12 ++++--------
 configure.ac                                        |    1 -
 desktop/source/deployment/registry/help/dp_help.cxx |    4 ++--
 sfx2/source/appl/app.cxx                            |    8 ++++----
 4 files changed, 10 insertions(+), 15 deletions(-)

New commits:
commit 2c38ea6d16b910294220cefaf8ae6a0683e6405a
Author: Tor Lillqvist <tml at iki.fi>
Date:   Thu Mar 28 11:46:27 2013 +0200

    Building without --with-help is not supposed to disable help functionality
    
    Drop HAVE_FEATURE_HELP. Just check HAVE_FEATURE_DESKTOP instead in the few
    places in the code where HAVE_FEATURE_HELP had been introduced so far. It's
    only for the non-desktop platforms that leaving out the traditional help
    functionality is intended anyway.
    
    Change-Id: I2d05869267f509a8e64cf402eed8ebef0020cada

diff --git a/config_host/config_features.h.in b/config_host/config_features.h.in
index 1cc2476..5d8e2d0 100644
--- a/config_host/config_features.h.in
+++ b/config_host/config_features.h.in
@@ -17,6 +17,10 @@
  * the LibreOffice code does not need to handle such things itself.
  *
  * Non-DESKTOP implies no traditional inter-app drag and drop concept.
+ *
+ * Non-DESKTOP implies no traditional help mechanism, and to some
+ * extent (as noticed, and as possible without making the code too
+ * ugly) the related code is ifdeffed out.
  */
 
 #define HAVE_FEATURE_DESKTOP 0
@@ -30,14 +34,6 @@
 
 #define HAVE_FEATURE_EXTENSIONS 0
 
-/* HELP - Whether we have the "normal" desktop-style help mechanism
- *
- * Can be turned on/off also for desktop environments with
- * --with-help, so thus a separate feature.
- */
-
-#define HAVE_FEATURE_HELP 0
-
 /* MULTIUSER_ENVIRONMENT - Wheter running on a "normal" multi-user
  * desktop (or server) OS
  *
diff --git a/configure.ac b/configure.ac
index 5fef541..998d9b0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4386,7 +4386,6 @@ AC_MSG_CHECKING([whether to build help])
 if test "$with_help" = "yes" -a $_os != iOS -a $_os != Android; then
     AC_MSG_RESULT([yes])
     BUILD_TYPE="$BUILD_TYPE HELP"
-    AC_DEFINE(HAVE_FEATURE_HELP)
     SCPDEFS="$SCPDEFS -DWITH_HELP"
     GIT_NEEDED_SUBMODULES="helpcontent2 $GIT_NEEDED_SUBMODULES"
 else
diff --git a/desktop/source/deployment/registry/help/dp_help.cxx b/desktop/source/deployment/registry/help/dp_help.cxx
index 35c798e..7510714 100644
--- a/desktop/source/deployment/registry/help/dp_help.cxx
+++ b/desktop/source/deployment/registry/help/dp_help.cxx
@@ -32,7 +32,7 @@
 #include "uno/current_context.hxx"
 #include "unotools/pathoptions.hxx"
 
-#if HAVE_FEATURE_HELP
+#if HAVE_FEATURE_DESKTOP
 #include <helpcompiler/compilehelp.hxx>
 #include <helpcompiler/HelpIndexer.hxx>
 #endif
@@ -387,7 +387,7 @@ void BackendImpl::implProcessHelp(
             data.dataUrl = xPackage->getURL();
             if (!package->extensionContainsCompiledHelp())
             {
-#if HAVE_FEATURE_HELP
+#if HAVE_FEATURE_DESKTOP
                 const OUString sHelpFolder = createFolder(OUString(), xCmdEnv);
                 data.dataUrl = sHelpFolder;
 
diff --git a/sfx2/source/appl/app.cxx b/sfx2/source/appl/app.cxx
index 2f90400..49ee2b1 100644
--- a/sfx2/source/appl/app.cxx
+++ b/sfx2/source/appl/app.cxx
@@ -130,7 +130,7 @@ SfxApplication* SfxApplication::pApp = NULL;
 static BasicDLL*       pBasic   = NULL;
 #endif
 
-#if HAVE_FEATURE_HELP
+#if HAVE_FEATURE_DESKTOP
 static SfxHelp*        pSfxHelp = NULL;
 #endif
 
@@ -167,7 +167,7 @@ SfxApplication* SfxApplication::GetOrCreate()
         ::framework::SetDockingWindowCreator( SfxDockingWindowFactory );
         ::framework::SetIsDockingWindowVisible( IsDockingWindowVisible );
         ::framework::SetActivateToolPanel( &SfxViewFrame::ActivateToolPanel );
-#if HAVE_FEATURE_HELP
+#if HAVE_FEATURE_DESKTOP
         Application::SetHelp( pSfxHelp );
         if ( SvtHelpOptions().IsHelpTips() )
             Help::EnableQuickHelp();
@@ -212,7 +212,7 @@ SfxApplication::SfxApplication()
     (void)bOk;
 #endif
 
-#if HAVE_FEATURE_HELP
+#if HAVE_FEATURE_DESKTOP
     pSfxHelp = new SfxHelp;
 #endif
 
@@ -231,7 +231,7 @@ SfxApplication::~SfxApplication()
 
     SfxModule::DestroyModules_Impl();
 
-#if HAVE_FEATURE_HELP
+#if HAVE_FEATURE_DESKTOP
     delete pSfxHelp;
     Application::SetHelp( NULL );
 #endif


More information about the Libreoffice-commits mailing list