Banner - shows some text before installation starts
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@1830 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
b295ba4ac5
commit
4828e0d292
6 changed files with 232 additions and 0 deletions
41
Contrib/Banner/Banner.c
Normal file
41
Contrib/Banner/Banner.c
Normal file
|
@ -0,0 +1,41 @@
|
|||
#include <windows.h>
|
||||
#include "../exdll/exdll.h"
|
||||
#include "../../Source/exehead/resource.h"
|
||||
|
||||
HINSTANCE hInstance;
|
||||
HWND hwBanner;
|
||||
|
||||
char buf[1024];
|
||||
|
||||
BOOL CALLBACK bannerProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
if (uMsg == WM_INITDIALOG)
|
||||
{
|
||||
popstring(buf);
|
||||
SetWindowText(hwndDlg,buf);
|
||||
SetDlgItemText(hwndDlg,IDC_STR,buf);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void __declspec(dllexport) show(HWND hwndParent, int string_size, char *variables, stack_t **stacktop)
|
||||
{
|
||||
EXDLL_INIT();
|
||||
|
||||
hwBanner = CreateDialog(
|
||||
GetModuleHandle(0),
|
||||
MAKEINTRESOURCE(IDD_VERIFY),
|
||||
hwndParent,
|
||||
bannerProc
|
||||
);
|
||||
}
|
||||
|
||||
void __declspec(dllexport) destroy(HWND hwndParent, int string_size, char *variables, stack_t **stacktop)
|
||||
{
|
||||
DestroyWindow(hwBanner);
|
||||
}
|
||||
|
||||
BOOL WINAPI _DllMainCRTStartup(HANDLE hInst, ULONG ul_reason_for_call, LPVOID lpReserved)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue