Added dialog class registration.

Patch by Thomas Weidenmueller.

svn path=/trunk/; revision=5290
This commit is contained in:
Eric Kohl 2003-07-27 17:48:43 +00:00
parent b7b1ad8ea9
commit 938493d413
3 changed files with 59 additions and 5 deletions

View file

@ -1,4 +1,4 @@
/* $Id: regcontrol.c,v 1.6 2003/07/11 18:00:14 sedwards Exp $
/* $Id: regcontrol.c,v 1.7 2003/07/27 17:47:35 ekohl Exp $
*
* COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS User32
@ -13,7 +13,7 @@
#include "user32/regcontrol.h"
static void RegisterBuiltinClass(const struct builtin_class_descr *Descr)
{
{
WNDCLASSA wca;
wca.lpszClassName = Descr->name;
@ -28,7 +28,7 @@ static void RegisterBuiltinClass(const struct builtin_class_descr *Descr)
wca.cbWndExtra = Descr->extra;
RegisterClassA(&wca);
}
}
/***********************************************************************
* ControlsInit
@ -37,6 +37,7 @@ static void RegisterBuiltinClass(const struct builtin_class_descr *Descr)
*/
void ControlsInit(void)
{
RegisterBuiltinClass(&DIALOG_builtin_class);
#if 0
RegisterBuiltinClass(&COMBO_builtin_class);
RegisterBuiltinClass(&COMBOLBOX_builtin_class);

View file

@ -1,5 +1,6 @@
#include <defines.h>
#include <reactos/resource.h>
#include <messages.h>
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
@ -43,7 +44,7 @@ OBM_CLOSE BITMAP "resources/obm_close.bmp"
// Dialog
//
MSGBOX DIALOG DISCARDABLE 100, 80, 216, 168
MSGBOX DIALOG DISCARDABLE 100, 80, 375, 168
STYLE DS_SYSMODAL | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION |
WS_SYSMENU
FONT 8, "MS Sans Serif"
@ -60,3 +61,35 @@ BEGIN
END
/* Menus */
EDITMENU MENU LOADONCALL MOVEABLE DISCARDABLE
{
POPUP ""
BEGIN
MENUITEM "&Undo", EM_UNDO
MENUITEM SEPARATOR
MENUITEM "Cu&t", WM_CUT
MENUITEM "&Copy", WM_COPY
MENUITEM "&Paste", WM_PASTE
MENUITEM "&Delete", WM_CLEAR
MENUITEM SEPARATOR
MENUITEM "Select &All", EM_SETSEL
END
}
SYSMENU MENU LOADONCALL MOVEABLE DISCARDABLE
{
MENUITEM "&Restore", 61728
MENUITEM "&Move", 61456
MENUITEM "&Size", 61440
MENUITEM "Mi&nimize", 61472
MENUITEM "Ma&ximize", 61488
MENUITEM SEPARATOR
MENUITEM "&Close\tAlt-F4", 61536
// MENUITEM SEPARATOR
// MENUITEM "&Switch to ...\tCtrl-Esc", 61744
// MENUITEM SEPARATOR
// MENUITEM "&About ReactOS ...", 61761
}

View file

@ -16,7 +16,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/* $Id: dialog.c,v 1.12 2003/07/26 23:12:08 royce Exp $
/* $Id: dialog.c,v 1.13 2003/07/27 17:48:43 ekohl Exp $
*
* PROJECT: ReactOS user32.dll
* FILE: lib/user32/windows/input.c
@ -38,6 +38,10 @@
#include <stdlib.h>
#include <debug.h>
#include "user32/regcontrol.h"
#include "../controls/controls.h"
/* MACROS/DEFINITIONS ********************************************************/
#define DF_END 0x0001
@ -111,6 +115,22 @@ typedef struct
HWND control;
} GETDLGITEMINFO;
/*********************************************************************
* dialog class descriptor
*/
const struct builtin_class_descr DIALOG_builtin_class =
{
DIALOG_CLASS_ATOMA, /* name */
CS_GLOBALCLASS | CS_SAVEBITS | CS_DBLCLKS, /* style */
(WNDPROC) DefDlgProcA, /* procA */
(WNDPROC) DefDlgProcW, /* procW */
sizeof(DIALOGINFO *), /* extra */
(LPCSTR) IDC_ARROW, /* cursor */
0 /* brush */
};
/* INTERNAL FUNCTIONS ********************************************************/
/***********************************************************************