fixed some compile errors caused by removing some config.h options

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@3429 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
kichik 2004-01-29 01:23:24 +00:00
parent 1d53ac7649
commit 851032d22a
6 changed files with 33 additions and 9 deletions

View file

@ -633,6 +633,8 @@ skipPage:
return HandleStaticBkColor();
}
#define this_page ((page*)lParam)
#ifdef NSIS_CONFIG_LICENSEPAGE
#define _RICHEDIT_VER 0x0200
@ -647,8 +649,6 @@ DWORD CALLBACK StreamLicense(DWORD dwCookie, LPBYTE pbBuff, LONG cb, LONG *pcb)
return 0;
}
#define this_page ((page*)lParam)
static BOOL CALLBACK LicenseProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
page *m_this_page=g_this_page;

View file

@ -133,9 +133,11 @@ static int NSISCALL ExecuteEntry(entry *entry_)
HWND hwSectionHack = g_SectionHack;
#endif
#ifdef NSIS_CONFIG_VISIBLE_SUPPORT
// Saves 8 bytes
HWND mainHwnd = g_hwnd;
#define g_hwnd mainHwnd
#endif
int exec_error = 0;

View file

@ -255,10 +255,14 @@ const char * NSISCALL loadHeaders(int cl_flags)
return _LANG_ERRORWRITINGTEMP;
}
dbd_srcpos = SetSelfFilePointer(g_filehdrsize + sizeof(firstheader));
#ifdef NSIS_CONFIG_CRC_SUPPORT
dbd_fulllen = dbd_srcpos - sizeof(h) + h.length_of_all_following_data - ((cl_flags & FH_FLAGS_NO_CRC) ? 0 : sizeof(int));
#else
dbd_fulllen = dbd_srcpos - sizeof(h) + h.length_of_all_following_data;
#endif//NSIS_CONFIG_CRC_SUPPORT
#else
SetSelfFilePointer(g_filehdrsize + sizeof(firstheader));
#endif
#endif//NSIS_COMPRESS_WHOLE
if (GetCompressedDataFromDataBlockToMemory(-1, data, h.length_of_header) != h.length_of_header)
{
@ -282,9 +286,10 @@ const char * NSISCALL loadHeaders(int cl_flags)
g_is_uninstaller++;
#endif
crc = BLOCKS_NUM;
while (crc--)
header->blocks[crc].offset += (int)data;
// set offsets to real memory offsets rather than installer's header offset
left = BLOCKS_NUM;
while (left--)
header->blocks[left].offset += (int)data;
#ifdef NSIS_COMPRESS_WHOLE
header->blocks[NB_DATA].offset = dbd_pos;

View file

@ -79,9 +79,11 @@ int NSISCALL my_GetDialogItemText(UINT idx, char *val)
int NSISCALL my_MessageBox(const char *text, UINT type) {
int _type = type & 0x000FFFFF;
#ifdef NSIS_CONFIG_SILENT_SUPPORT
// default for silent installers
if (g_exec_flags.silent && type >> 20)
return type >> 20;
#endif
// no silent or no default, just show
if (g_exec_flags.rtl)
_type ^= MB_RIGHT | MB_RTLREADING;