Available space now shown even if remote directory can't be found (\\remote\drive\dir_that_doesnt_exist will now give the avaible space)
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@2123 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
21fa9b890c
commit
d7561bbe5e
1 changed files with 6 additions and 6 deletions
|
@ -835,11 +835,15 @@ static BOOL CALLBACK DirProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar
|
||||||
GetUIText(IDC_DIR,state_install_directory,NSIS_MAX_STRLEN);
|
GetUIText(IDC_DIR,state_install_directory,NSIS_MAX_STRLEN);
|
||||||
is_valid_path=is_valid_instpath(state_install_directory);
|
is_valid_path=is_valid_instpath(state_install_directory);
|
||||||
|
|
||||||
mini_memcpy(s,state_install_directory,NSIS_MAX_STRLEN);
|
mystrcpy(s,state_install_directory);
|
||||||
s[sizeof(s)-1]=0;
|
|
||||||
if (s[1] == ':') s[3]=0;
|
if (s[1] == ':') s[3]=0;
|
||||||
else if (*(WORD*)s == CHAR2_TO_WORD('\\','\\')) // \\ path
|
else if (*(WORD*)s == CHAR2_TO_WORD('\\','\\')) // \\ path
|
||||||
{
|
{
|
||||||
|
char *p = mystrstr(s+2,"\\");
|
||||||
|
if (p) {
|
||||||
|
p = mystrstr(p+1,"\\");
|
||||||
|
if (p) *p = 0;
|
||||||
|
}
|
||||||
addtrailingslash(s);
|
addtrailingslash(s);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -857,12 +861,8 @@ static BOOL CALLBACK DirProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar
|
||||||
total+=g_inst_section[x].size_kb;
|
total+=g_inst_section[x].size_kb;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Added by Amir Szekely 24th July 2002
|
|
||||||
// Allows 'SpaceTexts none'
|
|
||||||
if (LANG_STR_TAB(LANG_SPACE_REQ)) {
|
if (LANG_STR_TAB(LANG_SPACE_REQ)) {
|
||||||
SetUITextNT(IDC_SPACEREQUIRED,inttosizestr(total,mystrcpy(s,LANG_STR(LANG_SPACE_REQ))));
|
SetUITextNT(IDC_SPACEREQUIRED,inttosizestr(total,mystrcpy(s,LANG_STR(LANG_SPACE_REQ))));
|
||||||
//if (available < total)
|
|
||||||
//SetTextColor(GetDC(GetDlgItem(hwndDlg,IDC_SPACEREQUIRED)), RGB(255,0,0));
|
|
||||||
if (available != -1)
|
if (available != -1)
|
||||||
SetUITextNT(IDC_SPACEAVAILABLE,inttosizestr(available,mystrcpy(s,LANG_STR(LANG_SPACE_AVAIL))));
|
SetUITextNT(IDC_SPACEAVAILABLE,inttosizestr(available,mystrcpy(s,LANG_STR(LANG_SPACE_AVAIL))));
|
||||||
else
|
else
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue