diff --git a/cck/ib/ib.cpp b/cck/ib/ib.cpp index f92737bdb5c0..cfdc632615d6 100644 --- a/cck/ib/ib.cpp +++ b/cck/ib/ib.cpp @@ -2,6 +2,7 @@ #include #include #include +#include #include "globals.h" #include "comp.h" #include "ib.h" @@ -13,6 +14,10 @@ #define MAX_SIZE 1024 #define CRVALUE 0x0D #define BUF_SIZE 4096 +// Required disk space for Win build +#define WDISK_SPACE 27577549 +// Required disk space for Linux build +#define LDISK_SPACE 84934656 int interpret(char *cmd); @@ -1205,6 +1210,35 @@ void CreateLinuxInstaller() _chdir(currentdir); } +void InsertComma(CString& requiredSpace) +{ + int len = requiredSpace.GetLength(); + int pos = len%3; + if (pos == 0) + pos = 3; + for(int i=pos; i 27,577,549) - ; - else + if ((nTotalAvailable.QuadPart) < WDISK_SPACE) { - AfxMessageBox("You dont have enough Disk space ", MB_OK); + DiskSpaceAlert(WDISK_SPACE,(nTotalAvailable.QuadPart)); return FALSE; - } + } } else { - if ((nTotalAvailable.QuadPart) > 84,934,656) - ; - else - { - AfxMessageBox("You dont have enough Disk space ", MB_OK); - return FALSE; - } + if ((nTotalAvailable.QuadPart) < LDISK_SPACE) + { + DiskSpaceAlert(LDISK_SPACE,(nTotalAvailable.QuadPart)); + return FALSE; + } } //Check for Disk space over