diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-12-10 22:51:57 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-12-12 09:38:59 +0000 |
commit | 38d2abde15fb4954a763bd31921a78ea660e54e5 (patch) | |
tree | f3a4530777dba1b4266c25d78a10e8741c01e281 /l10ntools | |
parent | 8a418586ea319f7ca7394e5412501fb8faed8142 (diff) |
sVersion, from WORK_STAMP doesn't get used
Diffstat (limited to 'l10ntools')
-rw-r--r-- | l10ntools/inc/srciter.hxx | 2 | ||||
-rw-r--r-- | l10ntools/source/localize.cxx | 24 | ||||
-rw-r--r-- | l10ntools/source/srciter.cxx | 11 |
3 files changed, 11 insertions, 26 deletions
diff --git a/l10ntools/inc/srciter.hxx b/l10ntools/inc/srciter.hxx index 5a1db39739bc..237e7a0026ab 100644 --- a/l10ntools/inc/srciter.hxx +++ b/l10ntools/inc/srciter.hxx @@ -46,7 +46,7 @@ protected: bool bSkipLinks; public: - SourceTreeIterator( const ByteString &rRootDirectory, const ByteString &rVersion ); + SourceTreeIterator(const rtl::OString &rRootDirectory); virtual ~SourceTreeIterator(); sal_Bool StartExecute(); diff --git a/l10ntools/source/localize.cxx b/l10ntools/source/localize.cxx index 53df0a1a4716..992683a79c28 100644 --- a/l10ntools/source/localize.cxx +++ b/l10ntools/source/localize.cxx @@ -205,7 +205,7 @@ private: ); void WorkOnDirectory( const ByteString &rDirectory ); public: - SourceTreeLocalizer( const ByteString &rRoot, const ByteString &rVersion , bool skip_links ); + SourceTreeLocalizer(const ByteString &rRoot, bool skip_links); ~SourceTreeLocalizer(); void SetLanguageRestriction( const ByteString& rRestrictions ) @@ -216,15 +216,12 @@ public: virtual void OnExecuteDirectory( const rtl::OUString &rDirectory ); }; -/*****************************************************************************/ -SourceTreeLocalizer::SourceTreeLocalizer( - const ByteString &rRoot, const ByteString &rVersion, bool skip_links ) -/*****************************************************************************/ - : SourceTreeIterator( rRoot, rVersion ), - nMode( LOCALIZE_NONE ), - nFileCnt( 0 ) +SourceTreeLocalizer::SourceTreeLocalizer(const ByteString &rRoot, bool skip_links) + : SourceTreeIterator(rRoot) + , nMode( LOCALIZE_NONE ) + , nFileCnt( 0 ) { - bSkipLinks = skip_links ; + bSkipLinks = skip_links ; } /*****************************************************************************/ @@ -594,13 +591,6 @@ int _cdecl main( int argc, char *argv[] ) else return Error(); - ByteString sVersion( Export::GetEnv( "WORK_STAMP" )); - - if ( !sVersion.Len() ) { - fprintf( stderr, "ERROR: No environment set!\n" ); - return 1; - } - DirEntry aEntry( String( sFileName , RTL_TEXTENCODING_ASCII_US )); aEntry.ToAbs(); String sFullEntry = aEntry.GetFull(); @@ -610,7 +600,7 @@ int _cdecl main( int argc, char *argv[] ) string pwd; Export::getCurrentDir( pwd ); cout << "Localizing directory " << pwd << "\n"; - SourceTreeLocalizer aIter( ByteString( pwd.c_str() ) , sVersion , bSkipLinks ); + SourceTreeLocalizer aIter( ByteString( pwd.c_str() ) , bSkipLinks ); aIter.SetLanguageRestriction( sLanguages ); aIter.Extract( sFileName ); printf("\n%d files found!\n",aIter.GetFileCnt()); diff --git a/l10ntools/source/srciter.cxx b/l10ntools/source/srciter.cxx index 829da3a473f5..4b89c65db1b6 100644 --- a/l10ntools/source/srciter.cxx +++ b/l10ntools/source/srciter.cxx @@ -35,15 +35,10 @@ // class SourceTreeIterator // -/*****************************************************************************/ -SourceTreeIterator::SourceTreeIterator( - const ByteString &rRootDirectory, const ByteString &rVersion ) -/*****************************************************************************/ - : bInExecute( sal_False ) +SourceTreeIterator::SourceTreeIterator(const rtl::OString &rRootDirectory) + : bInExecute( sal_False ) { - (void) rVersion ; - - rtl::OUString sRootDirectory( rRootDirectory.GetBuffer() , rRootDirectory.Len() , RTL_TEXTENCODING_UTF8 ); + rtl::OUString sRootDirectory(rtl::OStringToOUString(rRootDirectory, RTL_TEXTENCODING_UTF8)); aRootDirectory = transex::Directory( sRootDirectory ); } |