summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorPeter Burow <pb@openoffice.org>2001-03-22 13:25:49 +0000
committerPeter Burow <pb@openoffice.org>2001-03-22 13:25:49 +0000
commitae7dcbe040fb114bc8917c6462b49bffe18aa7ba (patch)
tree73024eac7d40706443fb9fa24639f59a7a728241 /sfx2
parentdac54775afccfd00ec7ec41bcecac748f714e72e (diff)
fix: #81086# GetHelpText() added
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/inc/sfxhelp.hxx8
-rw-r--r--sfx2/source/appl/sfxhelp.cxx25
2 files changed, 28 insertions, 5 deletions
diff --git a/sfx2/inc/sfxhelp.hxx b/sfx2/inc/sfxhelp.hxx
index 925e555af0b8..5ac24696351d 100644
--- a/sfx2/inc/sfxhelp.hxx
+++ b/sfx2/inc/sfxhelp.hxx
@@ -2,9 +2,9 @@
*
* $RCSfile: sfxhelp.hxx,v $
*
- * $Revision: 1.5 $
+ * $Revision: 1.6 $
*
- * last change: $Author: mba $ $Date: 2000-12-13 15:44:45 $
+ * last change: $Author: pb $ $Date: 2001-03-22 14:22:40 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -72,10 +72,12 @@ class SfxHelp_Impl : public Help
{
String aTicket; // for Plugins
String aUser;
+ sal_Bool bIsDebug;
private:
virtual BOOL Start( ULONG nHelpId );
String GetHelpModuleName( ULONG nHelpId );
+
public:
SfxHelp_Impl();
~SfxHelp_Impl();
@@ -83,6 +85,8 @@ public:
{ aTicket = rTicket;}
void SetUser( const String& rUser )
{ aUser = rUser;}
+
+ virtual XubString GetHelpText( ULONG nHelpId );
};
#endif // _PRIVATE
diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx
index addb1ab850c1..51686df6021d 100644
--- a/sfx2/source/appl/sfxhelp.cxx
+++ b/sfx2/source/appl/sfxhelp.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: sfxhelp.cxx,v $
*
- * $Revision: 1.22 $
+ * $Revision: 1.23 $
*
- * last change: $Author: mba $ $Date: 2001-02-09 11:39:29 $
+ * last change: $Author: pb $ $Date: 2001-03-22 14:25:49 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -139,8 +139,14 @@ void AppendConfigToken_Impl( String& rURL, sal_Bool bQuestionMark )
rURL += aHelpOpt.GetSystem();
}
-SfxHelp_Impl::SfxHelp_Impl()
+SfxHelp_Impl::SfxHelp_Impl() :
+
+ bIsDebug( sal_False )
+
{
+ char* pEnv = getenv( "help_debug" );
+ if ( pEnv )
+ bIsDebug = sal_True;
}
SfxHelp_Impl::~SfxHelp_Impl()
@@ -315,6 +321,19 @@ BOOL SfxHelp_Impl::Start( ULONG nHelpId )
return FALSE;
}
+XubString SfxHelp_Impl::GetHelpText( ULONG nHelpId )
+{
+ XubString aHelpText;
+ if ( bIsDebug )
+ {
+ aHelpText = GetHelpModuleName( nHelpId );
+ aHelpText += DEFINE_CONST_UNICODE(" - ");
+ aHelpText += String::CreateFromInt32( nHelpId );
+ }
+
+ return aHelpText;
+}
+
/*-----------------22.11.2000 10:59-----------------
* old code
BOOL SfxHelp_Impl::ImplStart( ULONG nHelpId, BOOL bCheckHelpFile, BOOL bChangeHelpFile, BOOL bHelpAgent )