--- a/ipsservices/ipssosplugin/src/ipsplgonlineoperation.cpp Thu Sep 30 11:43:07 2010 +0300
+++ b/ipsservices/ipssosplugin/src/ipsplgonlineoperation.cpp Thu Oct 14 17:33:43 2010 +0300
@@ -189,7 +189,7 @@
const TDesC8& aParams )
{
FUNC_LOG;
-
+
TMsvEntry tEntry;
TMsvId service;
if ( aSel.Count() )
@@ -242,6 +242,29 @@
}
}
+
+// ----------------------------------------------------------------------------
+// CIpsPlgOnlineOperation::EnoughDiskSpaceOnCurrentDrive()
+// Returns true if there is enough space on the disk for a file with given
+// file size.
+// ----------------------------------------------------------------------------
+//
+TBool CIpsPlgOnlineOperation::EnoughDiskSpaceOnCurrentDrive(
+ const TInt aFileSize ) const
+ {
+ TDriveUnit driveUnit;
+ TRAP_IGNORE( driveUnit = iMsvSession.CurrentDriveL() );
+ RFs rfs( iMsvSession.FileSession() );
+
+ TBool belowCriticalLevel( EFalse );
+
+ TRAP_IGNORE( belowCriticalLevel =
+ SysUtil::DiskSpaceBelowCriticalLevelL( &rfs, aFileSize, driveUnit ) );
+
+ return !belowCriticalLevel;
+ }
+
+
// <qmail> removed IpsOpType()
// <qmail> makes more sence to have this method here in "base" online op than in every derived class