Kaydet (Commit) 178b73da authored tarafından Miklos Vajna's avatar Miklos Vajna

sw: get rid of no longer needed TOOLS_CONSTASCII_STRINGPARAM define

Change-Id: I595907d345c0438858e53ca76fbb2ae7d79743e6
üst 94d7c1e4
...@@ -113,10 +113,6 @@ ...@@ -113,10 +113,6 @@
#define HTML_SPTYPE_HORI 2 #define HTML_SPTYPE_HORI 2
#define HTML_SPTYPE_VERT 3 #define HTML_SPTYPE_VERT 3
#ifndef TOOLS_CONSTASCII_STRINGPARAM
#define TOOLS_CONSTASCII_STRINGPARAM( constAsciiStr ) constAsciiStr, sizeof( constAsciiStr )-1
#endif
using editeng::SvxBorderLine; using editeng::SvxBorderLine;
using namespace ::com::sun::star; using namespace ::com::sun::star;
...@@ -148,17 +144,17 @@ HTMLReader::HTMLReader() ...@@ -148,17 +144,17 @@ HTMLReader::HTMLReader()
String HTMLReader::GetTemplateName() const String HTMLReader::GetTemplateName() const
{ {
String sTemplate(rtl::OUString("html")); OUString sTemplate("html");
String sTemplateWithoutExt( sTemplate ); OUString sTemplateWithoutExt( sTemplate );
// first search for OpenDocument Writer/Web template // first search for OpenDocument Writer/Web template
sTemplate.AppendAscii( TOOLS_CONSTASCII_STRINGPARAM(".oth") ); sTemplate += ".oth";
//Added path for the common HTML template //Added path for the common HTML template
SvtPathOptions aPathOpt; SvtPathOptions aPathOpt;
const String sCommonTemplatePath("share/template/common/internal"); const String sCommonTemplatePath("share/template/common/internal");
aPathOpt.SetTemplatePath(sCommonTemplatePath); aPathOpt.SetTemplatePath(sCommonTemplatePath);
// OpenDocument Writer/Web template (extension .oth) // OpenDocument Writer/Web template (extension .oth)
sal_Bool bSet = aPathOpt.SearchFile( sTemplate, SvtPathOptions::PATH_TEMPLATE ); sal_Bool bSet = aPathOpt.SearchFile( String().Assign(sTemplate), SvtPathOptions::PATH_TEMPLATE );
if( !bSet ) if( !bSet )
{ {
...@@ -166,13 +162,13 @@ String HTMLReader::GetTemplateName() const ...@@ -166,13 +162,13 @@ String HTMLReader::GetTemplateName() const
sTemplate = sTemplateWithoutExt; sTemplate = sTemplateWithoutExt;
// no OpenDocument Writer/Web template found. // no OpenDocument Writer/Web template found.
// search for OpenOffice.org Writer/Web template // search for OpenOffice.org Writer/Web template
sTemplate.AppendAscii( TOOLS_CONSTASCII_STRINGPARAM(".stw") ); sTemplate += ".stw";
bSet = aPathOpt.SearchFile( sTemplate, SvtPathOptions::PATH_TEMPLATE ); bSet = aPathOpt.SearchFile( String().Assign(sTemplate), SvtPathOptions::PATH_TEMPLATE );
} }
if( !bSet ) if( !bSet )
{ {
sTemplate.Erase(); sTemplate = "";
OSL_ENSURE( !this, OSL_ENSURE( !this,
"Die html.vor befindet sich nicht mehr im definierten Directory!"); "Die html.vor befindet sich nicht mehr im definierten Directory!");
} }
......
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