ReactOS  0.4.12-dev-57-g7050ac4
about.c File Reference
#include "precomp.h"
Include dependency graph for about.c:

Go to the source code of this file.

Functions

static INT_PTR CALLBACK AboutDialogProc (HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
 
VOID ShowAboutDlg (HWND hWndParent)
 

Function Documentation

◆ AboutDialogProc()

static INT_PTR CALLBACK AboutDialogProc ( HWND  hDlg,
UINT  message,
WPARAM  wParam,
LPARAM  lParam 
)
static

Definition at line 15 of file about.c.

Referenced by MainWndCommand(), and ShowAboutDlg().

19 {
20  static HICON hIcon = NULL;
21 
22  switch (message)
23  {
24  case WM_INITDIALOG:
25  {
26  HWND hLicenseEditWnd;
27  WCHAR strLicense[700];
28 
29  hIcon = LoadImageW(hInstance,
31  IMAGE_ICON,
32  16,
33  16,
34  0);
35  if (hIcon)
36  {
37  SendMessageW(hDlg,
38  WM_SETICON,
39  ICON_SMALL,
40  (LPARAM)hIcon);
41  }
42 
43  hLicenseEditWnd = GetDlgItem(hDlg,
45 
48  strLicense,
49  sizeof(strLicense) / sizeof(WCHAR)))
50  {
51  SetWindowTextW(hLicenseEditWnd,
52  strLicense);
53  }
54 
55  return TRUE;
56  }
57 
58  case WM_COMMAND:
59  {
60  if ((LOWORD(wParam) == IDOK) || (LOWORD(wParam) == IDCANCEL))
61  {
62  DestroyIcon(hIcon);
63  EndDialog(hDlg,
64  LOWORD(wParam));
65  return TRUE;
66  }
67 
68  break;
69  }
70  }
71 
72  return FALSE;
73 }
#define IDI_ICON
Definition: resource.h:5
Definition: tftpd.h:59
static HICON
Definition: imagelist.c:84
#define TRUE
Definition: types.h:120
#define IDOK
Definition: winuser.h:824
#define IMAGE_ICON
Definition: winuser.h:212
BOOL WINAPI DestroyIcon(_In_ HICON)
Definition: cursoricon.c:2022
__wchar_t WCHAR
Definition: xmlstorage.h:180
BOOL WINAPI SetWindowTextW(_In_ HWND, _In_opt_ LPCWSTR)
int WINAPI LoadStringW(_In_opt_ HINSTANCE hInstance, _In_ UINT uID, _Out_writes_to_(cchBufferMax, return+1) LPWSTR lpBuffer, _In_ int cchBufferMax)
BOOL WINAPI EndDialog(_In_ HWND, _In_ INT_PTR)
WPARAM wParam
Definition: combotst.c:138
#define ICON_SMALL
Definition: tnclass.cpp:48
HINSTANCE hInstance
Definition: charmap.c:20
HANDLE WINAPI LoadImageW(_In_opt_ HINSTANCE, _In_ LPCWSTR, _In_ UINT, _In_ int, _In_ int, _In_ UINT)
Definition: cursoricon.c:2172
LONG_PTR LPARAM
Definition: windef.h:208
smooth NULL
Definition: ftsmooth.c:416
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
#define WM_COMMAND
Definition: winuser.h:1716
#define IDS_LICENSE
Definition: resource.h:28
HICON hIcon
Definition: msconfig.c:44
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
#define MAKEINTRESOURCEW(i)
Definition: winuser.h:582
#define IDCANCEL
Definition: winuser.h:825
#define WM_INITDIALOG
Definition: winuser.h:1715
#define LOWORD(l)
Definition: pedump.c:82
#define IDC_LICENSE_EDIT
Definition: resource.h:20

◆ ShowAboutDlg()

VOID ShowAboutDlg ( HWND  hWndParent)

Definition at line 77 of file about.c.

Referenced by PanelWndProc().

78 {
81  hWndParent,
83 }
HINSTANCE hInstance
Definition: charmap.c:20
#define IDD_ABOUTBOX
Definition: resource.h:8
static INT_PTR CALLBACK AboutDialogProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
Definition: about.c:15
#define DialogBoxW(i, t, p, f)
Definition: winuser.h:4268
#define MAKEINTRESOURCEW(i)
Definition: winuser.h:582