2002-09-10 02:07:02 +00:00
|
|
|
/*
|
|
|
|
* ReactOS Task Manager
|
|
|
|
*
|
|
|
|
* about.cpp
|
|
|
|
*
|
|
|
|
* Copyright (C) 1999 - 2001 Brian Palmer <brianp@reactos.org>
|
|
|
|
*
|
2004-01-07 18:57:22 +00:00
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2.1 of the License, or (at your option) any later version.
|
2002-09-10 02:07:02 +00:00
|
|
|
*
|
2004-01-07 18:57:22 +00:00
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
2002-09-10 02:07:02 +00:00
|
|
|
*
|
2004-01-07 18:57:22 +00:00
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
2002-09-10 02:07:02 +00:00
|
|
|
*/
|
2004-01-09 23:00:43 +00:00
|
|
|
|
|
|
|
#define WIN32_LEAN_AND_MEAN /* Exclude rarely-used stuff from Windows headers */
|
2002-09-10 02:07:02 +00:00
|
|
|
#include <windows.h>
|
|
|
|
#include <commctrl.h>
|
|
|
|
#include <stdlib.h>
|
|
|
|
#include <malloc.h>
|
|
|
|
#include <memory.h>
|
|
|
|
#include <tchar.h>
|
|
|
|
#include <stdio.h>
|
2004-01-09 23:00:43 +00:00
|
|
|
|
2002-09-10 02:07:02 +00:00
|
|
|
#include "taskmgr.h"
|
|
|
|
#include "about.h"
|
|
|
|
|
|
|
|
LRESULT CALLBACK AboutDialogWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
|
|
|
|
|
|
|
|
void OnAbout(void)
|
|
|
|
{
|
2004-01-09 23:00:43 +00:00
|
|
|
DialogBox(hInst, MAKEINTRESOURCE(IDD_ABOUTBOX), hMainWnd, (DLGPROC)AboutDialogWndProc);
|
2002-09-10 02:07:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
LRESULT CALLBACK AboutDialogWndProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
|
|
|
|
{
|
2004-01-09 23:00:43 +00:00
|
|
|
HWND hLicenseEditWnd;
|
|
|
|
TCHAR strLicense[0x1000];
|
2002-09-10 02:07:02 +00:00
|
|
|
|
2004-01-09 23:00:43 +00:00
|
|
|
switch (message)
|
|
|
|
{
|
|
|
|
case WM_INITDIALOG:
|
2002-09-10 02:07:02 +00:00
|
|
|
|
2004-01-09 23:00:43 +00:00
|
|
|
hLicenseEditWnd = GetDlgItem(hDlg, IDC_LICENSE_EDIT);
|
2002-09-10 02:07:02 +00:00
|
|
|
|
2004-01-09 23:00:43 +00:00
|
|
|
LoadString(hInst, IDS_LICENSE, strLicense, 0x1000);
|
2002-09-10 02:07:02 +00:00
|
|
|
|
2004-01-09 23:00:43 +00:00
|
|
|
SetWindowText(hLicenseEditWnd, strLicense);
|
2002-09-10 02:07:02 +00:00
|
|
|
|
2004-01-09 23:00:43 +00:00
|
|
|
return TRUE;
|
2002-09-10 02:07:02 +00:00
|
|
|
|
2004-01-09 23:00:43 +00:00
|
|
|
case WM_COMMAND:
|
2002-09-10 02:07:02 +00:00
|
|
|
|
2004-01-09 23:00:43 +00:00
|
|
|
if ((LOWORD(wParam) == IDOK) || (LOWORD(wParam) == IDCANCEL))
|
|
|
|
{
|
|
|
|
EndDialog(hDlg, LOWORD(wParam));
|
|
|
|
return TRUE;
|
|
|
|
}
|
2002-09-10 02:07:02 +00:00
|
|
|
|
2004-01-09 23:00:43 +00:00
|
|
|
break;
|
|
|
|
}
|
2002-09-10 02:07:02 +00:00
|
|
|
|
|
|
|
return 0;
|
|
|
|
}
|