@ -27,8 +27,8 @@ bool PURL::Url::copyTo(const Url &destination, Log::Generic &log) const
// }
//#else
// do not overwrite
bool ok = K IO: : NetAccess : : file_copy ( _url , destination . _url , - 1 , false , false , tqApp - > mainWidget ( ) ) ;
if ( ! ok ) log . sorry ( i18n ( " Could not copy file " ) , K IO: : NetAccess : : lastErrorString ( ) ) ;
bool ok = TDE IO: : NetAccess : : file_copy ( _url , destination . _url , - 1 , false , false , tqApp - > mainWidget ( ) ) ;
if ( ! ok ) log . sorry ( i18n ( " Could not copy file " ) , TDE IO: : NetAccess : : lastErrorString ( ) ) ;
return ok ;
//#endif
}
@ -44,12 +44,12 @@ bool PURL::Url::create(Log::Generic &log) const
// }
//#else
// assume file do no exist if ioslave cannot tell...
if ( K IO: : NetAccess : : exists ( _url , false , tqApp - > mainWidget ( ) ) ) return true ;
if ( TDE IO: : NetAccess : : exists ( _url , false , tqApp - > mainWidget ( ) ) ) return true ;
KTempFile tmp ;
tmp . setAutoDelete ( true ) ;
// do not overwrite
bool ok = K IO: : NetAccess : : file_copy ( tmp . name ( ) , _url , - 1 , false , false , tqApp - > mainWidget ( ) ) ;
if ( ! ok ) log . sorry ( i18n ( " Could not create file " ) , K IO: : NetAccess : : lastErrorString ( ) ) ;
bool ok = TDE IO: : NetAccess : : file_copy ( tmp . name ( ) , _url , - 1 , false , false , tqApp - > mainWidget ( ) ) ;
if ( ! ok ) log . sorry ( i18n ( " Could not create file " ) , TDE IO: : NetAccess : : lastErrorString ( ) ) ;
//#endif
return ok ;
}
@ -71,8 +71,8 @@ bool PURL::Url::del(Log::Generic &log) const
// return false;
// }
//#else
bool ok = K IO: : NetAccess : : del ( _url , tqApp - > mainWidget ( ) ) ;
if ( ! ok ) log . sorry ( i18n ( " Could not delete file. " ) , K IO: : NetAccess : : lastErrorString ( ) ) ;
bool ok = TDE IO: : NetAccess : : del ( _url , tqApp - > mainWidget ( ) ) ;
if ( ! ok ) log . sorry ( i18n ( " Could not delete file. " ) , TDE IO: : NetAccess : : lastErrorString ( ) ) ;
return ok ;
//#endif
}
@ -103,9 +103,9 @@ bool PURL::Directory::create(Log::Generic &log) const
// }
//#else
// assume dir do no exist if ioslave cannot tell...
if ( K IO: : NetAccess : : exists ( _url , false , tqApp - > mainWidget ( ) ) ) return true ;
bool ok = K IO: : NetAccess : : mkdir ( _url , tqApp - > mainWidget ( ) ) ;
if ( ! ok ) log . sorry ( i18n ( " Could not create directory " ) , K IO: : NetAccess : : lastErrorString ( ) ) ;
if ( TDE IO: : NetAccess : : exists ( _url , false , tqApp - > mainWidget ( ) ) ) return true ;
bool ok = TDE IO: : NetAccess : : mkdir ( _url , tqApp - > mainWidget ( ) ) ;
if ( ! ok ) log . sorry ( i18n ( " Could not create directory " ) , TDE IO: : NetAccess : : lastErrorString ( ) ) ;
//#endif
return ok ;
}