Kaydet (Commit) 85977320 authored tarafından Xisco Fauli's avatar Xisco Fauli Kaydeden (comit) Noel Grandin

tdf#89329: use unique_ptr for pImpl in sfxhelp

Change-Id: I357b53f644384452c5dc2b74d3aba3d3dafae00e
Reviewed-on: https://gerrit.libreoffice.org/25314Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarNoel Grandin <noelgrandin@gmail.com>
üst f90b77d0
......@@ -24,13 +24,14 @@
#include <sfx2/dllapi.h>
#include <sal/types.h>
#include <vcl/help.hxx>
#include <memory>
class SfxHelp_Impl;
class SfxFrame;
class SFX2_DLLPUBLIC SfxHelp : public Help
{
bool bIsDebug;
SfxHelp_Impl* pImp;
std::unique_ptr< SfxHelp_Impl > pImpl;
private:
SAL_DLLPRIVATE bool Start_Impl( const OUString& rURL, const vcl::Window* pWindow, const OUString& rKeyword );
......
......@@ -218,7 +218,7 @@ OUString SfxHelp_Impl::GetHelpText( const OUString& aCommandURL, const OUString&
SfxHelp::SfxHelp() :
bIsDebug( false ),
pImp ( nullptr )
pImpl( new SfxHelp_Impl )
{
// read the environment variable "HELP_DEBUG"
// if it's set, you will see debug output on active help
......@@ -228,13 +228,10 @@ SfxHelp::SfxHelp() :
osl_getEnvironment( sEnvVarName.pData, &sHelpDebug.pData );
bIsDebug = !sHelpDebug.isEmpty();
}
pImp = new SfxHelp_Impl();
}
SfxHelp::~SfxHelp()
{
delete pImp;
}
OUString getDefaultModule_Impl()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment