Removed "About NSIS" dialog
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@1351 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
b6ff897788
commit
eb27ee547b
4 changed files with 15 additions and 120 deletions
|
@ -215,11 +215,6 @@ BOOL CALLBACK DialogProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) {
|
|||
DialogBox(g_hInstance,MAKEINTRESOURCE(DLG_ABOUT),g_hwnd,(DLGPROC)AboutProc);
|
||||
return TRUE;
|
||||
}
|
||||
case IDM_ABOUTNSIS:
|
||||
{
|
||||
DialogBox(g_hInstance,MAKEINTRESOURCE(DLG_ABOUTNSIS),g_hwnd,(DLGPROC)AboutNSISProc);
|
||||
return TRUE;
|
||||
}
|
||||
case IDM_NSISHOME:
|
||||
{
|
||||
ShellExecute(g_hwnd,"open",NSIS_URL,NULL,NULL,SW_SHOWNORMAL);
|
||||
|
@ -469,80 +464,6 @@ char * ContribUsers[] = {
|
|||
|
||||
extern char *g_branding;
|
||||
|
||||
BOOL CALLBACK AboutNSISProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) {
|
||||
switch(msg) {
|
||||
case WM_INITDIALOG:
|
||||
{
|
||||
HFONT bfont = CreateFont(14,0,0,0,FW_BOLD,FALSE,FALSE,FALSE,DEFAULT_CHARSET,
|
||||
OUT_DEFAULT_PRECIS,CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY,
|
||||
FIXED_PITCH|FF_DONTCARE, "MS Shell Dlg");
|
||||
HFONT hFont = CreateFont(12,0,0,0,FW_NORMAL,0,0,0,DEFAULT_CHARSET,OUT_CHARACTER_PRECIS,CLIP_DEFAULT_PRECIS,DEFAULT_QUALITY,FIXED_PITCH|FF_DONTCARE,"MS Shell Dlg");
|
||||
if (bfont) SendDlgItemMessage(hwndDlg, IDC_NSISVER, WM_SETFONT, (WPARAM)bfont, FALSE);
|
||||
SetDlgItemText(hwndDlg,IDC_NSISVER,g_branding);
|
||||
SendDlgItemMessage(hwndDlg,IDC_NSISNFO,WM_SETFONT,(WPARAM)hFont,0);
|
||||
SendDlgItemMessage(hwndDlg,IDC_NSISNFO,EM_SETBKGNDCOLOR,0,GetSysColor(COLOR_BTNFACE));
|
||||
{
|
||||
char *s;
|
||||
s = (char *)GlobalAlloc(GPTR,lstrlen(EXENAME)+10);
|
||||
wsprintf(s,"%s /license",EXENAME);
|
||||
STARTUPINFO si={sizeof(si),};
|
||||
SECURITY_ATTRIBUTES sa={sizeof(sa),};
|
||||
SECURITY_DESCRIPTOR sd={0,};
|
||||
PROCESS_INFORMATION pi={0,};
|
||||
HANDLE newstdout=0,read_stdout=0;
|
||||
|
||||
OSVERSIONINFO osv={sizeof(osv)};
|
||||
GetVersionEx(&osv);
|
||||
if (osv.dwPlatformId == VER_PLATFORM_WIN32_NT) {
|
||||
InitializeSecurityDescriptor(&sd,SECURITY_DESCRIPTOR_REVISION);
|
||||
SetSecurityDescriptorDacl(&sd,true,NULL,false);
|
||||
sa.lpSecurityDescriptor = &sd;
|
||||
}
|
||||
else sa.lpSecurityDescriptor = NULL;
|
||||
sa.bInheritHandle = true;
|
||||
if (!CreatePipe(&read_stdout,&newstdout,&sa,0)) {
|
||||
return 0;
|
||||
}
|
||||
GetStartupInfo(&si);
|
||||
si.dwFlags = STARTF_USESTDHANDLES|STARTF_USESHOWWINDOW;
|
||||
si.wShowWindow = SW_HIDE;
|
||||
si.hStdOutput = newstdout;
|
||||
si.hStdError = newstdout;
|
||||
if (!CreateProcess(NULL,s,NULL,NULL,TRUE,CREATE_NEW_CONSOLE,NULL,NULL,&si,&pi)) {
|
||||
CloseHandle(newstdout);
|
||||
CloseHandle(read_stdout);
|
||||
return 0;
|
||||
}
|
||||
char szBuf[2048];
|
||||
DWORD dwRead = 1;
|
||||
DWORD dwExit = !STILL_ACTIVE;
|
||||
if (WaitForSingleObject(pi.hProcess,10000)!=WAIT_OBJECT_0) {
|
||||
return 0;
|
||||
}
|
||||
ReadFile(read_stdout, szBuf, sizeof(szBuf)-1, &dwRead, NULL);
|
||||
szBuf[dwRead] = 0;
|
||||
if (lstrlen(szBuf)==0) EndDialog(hwndDlg,TRUE);
|
||||
SetDlgItemText(hwndDlg,IDC_NSISNFO,szBuf);
|
||||
GlobalFree(s);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case WM_CLOSE:
|
||||
EndDialog(hwndDlg, TRUE);
|
||||
break;
|
||||
case WM_COMMAND:
|
||||
{
|
||||
switch (LOWORD(wParam)) {
|
||||
case WM_CLOSE:
|
||||
case IDOK:
|
||||
EndDialog(hwndDlg, TRUE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL CALLBACK AboutProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) {
|
||||
static HBRUSH hBrush;
|
||||
switch(msg) {
|
||||
|
@ -554,11 +475,16 @@ BOOL CALLBACK AboutProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) {
|
|||
HFONT rfont = CreateFont(12,0,0,0,FW_NORMAL,FALSE,FALSE,FALSE,DEFAULT_CHARSET,
|
||||
OUT_DEFAULT_PRECIS,CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY,
|
||||
FIXED_PITCH|FF_DONTCARE, "MS Shell Dlg");
|
||||
HFONT sfont = CreateFont(11,0,0,0,FW_NORMAL,FALSE,FALSE,FALSE,DEFAULT_CHARSET,
|
||||
OUT_DEFAULT_PRECIS,CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY,
|
||||
FIXED_PITCH|FF_DONTCARE, "MS Shell Dlg");
|
||||
if (bfont) SendDlgItemMessage(hwndDlg, IDC_ABOUTVERSION, WM_SETFONT, (WPARAM)bfont, FALSE);
|
||||
if (rfont) {
|
||||
SendDlgItemMessage(hwndDlg, IDC_ABOUTCOPY, WM_SETFONT, (WPARAM)rfont, FALSE);
|
||||
SendDlgItemMessage(hwndDlg, IDC_ABOUTPORTIONS, WM_SETFONT, (WPARAM)rfont, FALSE);
|
||||
}
|
||||
if (sfont) SendDlgItemMessage(hwndDlg, IDC_NSISVER, WM_SETFONT, (WPARAM)rfont, FALSE);
|
||||
SetDlgItemText(hwndDlg,IDC_NSISVER,g_branding);
|
||||
SetDlgItemText(hwndDlg,IDC_ABOUTVERSION,NSISW_VERSION);
|
||||
SetDlgItemText(hwndDlg,IDC_ABOUTCOPY,COPYRIGHT);
|
||||
HWND ilist = GetDlgItem(hwndDlg,IDC_CONTRIB);
|
||||
|
@ -580,13 +506,9 @@ BOOL CALLBACK AboutProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam) {
|
|||
SelectObject((HDC)wParam, hBrush);
|
||||
return((LONG)hBrush);
|
||||
}
|
||||
case WM_CLOSE:
|
||||
EndDialog(hwndDlg, TRUE);
|
||||
break;
|
||||
case WM_COMMAND:
|
||||
{
|
||||
switch (LOWORD(wParam)) {
|
||||
case WM_CLOSE:
|
||||
case IDOK:
|
||||
EndDialog(hwndDlg, TRUE);
|
||||
break;
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
#define IDM_MENU 104
|
||||
#define IDK_ACCEL 105
|
||||
#define IDI_SHELL 112
|
||||
#define DLG_ABOUTNSIS 113
|
||||
#define IDC_LOGWIN 402
|
||||
#define IDC_VERSION 405
|
||||
#define IDC_CLOSE 406
|
||||
|
@ -25,14 +24,12 @@
|
|||
#define IDC_ABOUTPORTIONS 1005
|
||||
#define IDC_CONTRIB 1009
|
||||
#define IDC_NSISVER 1010
|
||||
#define IDC_NSISNFO 1011
|
||||
#define IDM_TEST 40002
|
||||
#define IDM_EDITSCRIPT 40003
|
||||
#define IDM_DOCS 40004
|
||||
#define IDM_LOADSCRIPT 40005
|
||||
#define IDM_FIND 40006
|
||||
#define IDM_SELECTALL 40007
|
||||
#define IDM_ABOUTNSIS 40008
|
||||
#define IDM_CLEARLOG 40009
|
||||
|
||||
// Next default values for new objects
|
||||
|
|
|
@ -93,7 +93,6 @@ BEGIN
|
|||
MENUITEM "NSIS Home", IDM_NSISHOME
|
||||
MENUITEM "Documentation\tF1", IDM_DOCS
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "About &NSIS", IDM_ABOUTNSIS
|
||||
MENUITEM "&About MakeNSISW", IDM_ABOUT
|
||||
END
|
||||
END
|
||||
|
@ -140,36 +139,21 @@ BEGIN
|
|||
PUSHBUTTON "&Test Installer",IDC_TEST,230,208,60,15,WS_DISABLED
|
||||
END
|
||||
|
||||
DLG_ABOUT DIALOGEX 0, 0, 235, 105
|
||||
STYLE DS_MODALFRAME | DS_3DLOOK | DS_CENTER | WS_POPUP | WS_CAPTION |
|
||||
WS_SYSMENU
|
||||
DLG_ABOUT DIALOGEX 0, 0, 235, 108
|
||||
STYLE DS_MODALFRAME | DS_3DLOOK | DS_CENTER | WS_POPUP | WS_CAPTION
|
||||
CAPTION "About MakeNSISW"
|
||||
FONT 8, "MS Shell Dlg", 0, 0, 0x1
|
||||
BEGIN
|
||||
ICON IDI_ICON,IDC_STATIC,7,4,21,20
|
||||
DEFPUSHBUTTON "Clo&se",IDOK,185,86,43,15
|
||||
LTEXT "MakeNSISW",IDC_ABOUTVERSION,44,4,184,8
|
||||
LTEXT "Copyright",IDC_ABOUTCOPY,44,18,184,8
|
||||
CONTROL "",IDC_STATIC,"Static",SS_ETCHEDHORZ,47,78,181,1
|
||||
LTEXT "Other Contributors:",IDC_ABOUTPORTIONS,44,30,184,10
|
||||
LISTBOX IDC_CONTRIB,48,40,179,33,LBS_SORT | LBS_NOINTEGRALHEIGHT |
|
||||
LTEXT "MakeNSISW",IDC_ABOUTVERSION,40,4,184,8
|
||||
LTEXT "Copyright",IDC_ABOUTCOPY,40,21,184,8
|
||||
CONTROL "",IDC_STATIC,"Static",SS_ETCHEDHORZ,40,80,189,1
|
||||
LTEXT "Other Contributors:",IDC_ABOUTPORTIONS,40,32,184,10
|
||||
LISTBOX IDC_CONTRIB,45,42,179,33,LBS_SORT | LBS_NOINTEGRALHEIGHT |
|
||||
LBS_NOSEL | NOT WS_BORDER | WS_VSCROLL | WS_TABSTOP,
|
||||
WS_EX_TRANSPARENT
|
||||
END
|
||||
|
||||
DLG_ABOUTNSIS DIALOG DISCARDABLE 0, 0, 292, 161
|
||||
STYLE DS_MODALFRAME | DS_3DLOOK | DS_CENTER | WS_POPUP | WS_CAPTION |
|
||||
WS_SYSMENU
|
||||
CAPTION "About NSIS"
|
||||
FONT 8, "MS Sans Serif"
|
||||
BEGIN
|
||||
DEFPUSHBUTTON "&Close",IDOK,235,140,50,15
|
||||
ICON IDI_ICON,IDC_STATIC,7,7,21,20
|
||||
LTEXT "NSIS",IDC_NSISVER,38,13,90,11
|
||||
CONTROL "",IDC_STATIC,"Static",SS_ETCHEDHORZ,7,133,278,1
|
||||
CONTROL "",IDC_NSISNFO,"RICHEDIT",ES_MULTILINE | ES_AUTOVSCROLL |
|
||||
ES_NOHIDESEL | ES_READONLY | ES_NUMBER | WS_BORDER |
|
||||
WS_VSCROLL,7,32,278,97
|
||||
LTEXT "NSIS",IDC_NSISVER,44,89,135,8,WS_DISABLED
|
||||
END
|
||||
|
||||
|
||||
|
@ -186,15 +170,7 @@ BEGIN
|
|||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 228
|
||||
TOPMARGIN, 4
|
||||
BOTTOMMARGIN, 101
|
||||
END
|
||||
|
||||
DLG_ABOUTNSIS, DIALOG
|
||||
BEGIN
|
||||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 285
|
||||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 154
|
||||
BOTTOMMARGIN, 103
|
||||
END
|
||||
END
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
|
|
@ -178,7 +178,7 @@ void CompileNSISScript() {
|
|||
g_script = s;
|
||||
g_appended = TRUE;
|
||||
}
|
||||
g_dwLength = 0;
|
||||
g_dwLength = 0;
|
||||
// Disable buttons during compile
|
||||
DisableItems(g_hwnd);
|
||||
DWORD id;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue