Large-scale renaming of all Win32 functions and types to use the
standard Windows names.
diff --git a/controls/menu.c b/controls/menu.c
index b1a1445..d6f36bf 100644
--- a/controls/menu.c
+++ b/controls/menu.c
@@ -44,17 +44,17 @@
/* Menu item structure */
typedef struct {
/* ----------- MENUITEMINFO Stuff ----------- */
- UINT32 fType; /* Item type. */
- UINT32 fState; /* Item state. */
- UINT32 wID; /* Item id. */
- HMENU32 hSubMenu; /* Pop-up menu. */
- HBITMAP32 hCheckBit; /* Bitmap when checked. */
- HBITMAP32 hUnCheckBit; /* Bitmap when unchecked. */
+ UINT fType; /* Item type. */
+ UINT fState; /* Item state. */
+ UINT wID; /* Item id. */
+ HMENU hSubMenu; /* Pop-up menu. */
+ HBITMAP hCheckBit; /* Bitmap when checked. */
+ HBITMAP hUnCheckBit; /* Bitmap when unchecked. */
LPSTR text; /* Item text or bitmap handle. */
DWORD dwItemData; /* Application defined. */
/* ----------- Wine stuff ----------- */
- RECT32 rect; /* Item area (relative to menu window) */
- UINT32 xTab; /* X position of text after Tab */
+ RECT rect; /* Item area (relative to menu window) */
+ UINT xTab; /* X position of text after Tab */
} MENUITEM;
/* Popup menu structure */
@@ -65,9 +65,9 @@
WORD Width; /* Width of the whole menu */
WORD Height; /* Height of the whole menu */
WORD nItems; /* Number of items in the menu */
- HWND32 hWnd; /* Window containing the menu */
+ HWND hWnd; /* Window containing the menu */
MENUITEM *items; /* Array of menu items */
- UINT32 FocusedItem; /* Currently focused item */
+ UINT FocusedItem; /* Currently focused item */
WORD defitem; /* default item position. Unused (except for set/get)*/
} POPUPMENU, *LPPOPUPMENU;
@@ -79,11 +79,11 @@
typedef struct
{
- UINT32 trackFlags;
- HMENU32 hCurrentMenu; /* current submenu (can be equal to hTopMenu)*/
- HMENU32 hTopMenu; /* initial menu */
- HWND32 hOwnerWnd; /* where notifications are sent */
- POINT32 pt;
+ UINT trackFlags;
+ HMENU hCurrentMenu; /* current submenu (can be equal to hTopMenu)*/
+ HMENU hTopMenu; /* initial menu */
+ HWND hOwnerWnd; /* where notifications are sent */
+ POINT pt;
} MTRACKER;
#define MENU_MAGIC 0x554d /* 'MU' */
@@ -134,30 +134,30 @@
static WORD check_bitmap_width = 0, check_bitmap_height = 0;
static WORD arrow_bitmap_width = 0, arrow_bitmap_height = 0;
-static HBITMAP32 hStdRadioCheck = 0;
-static HBITMAP32 hStdCheck = 0;
-static HBITMAP32 hStdMnArrow = 0;
+static HBITMAP hStdRadioCheck = 0;
+static HBITMAP hStdCheck = 0;
+static HBITMAP hStdMnArrow = 0;
// Minimze/restore/close buttons to be inserted in menubar
-static HBITMAP32 hBmpMinimize = 0;
-static HBITMAP32 hBmpMinimizeD = 0;
-static HBITMAP32 hBmpMaximize = 0;
-static HBITMAP32 hBmpMaximizeD = 0;
-static HBITMAP32 hBmpClose = 0;
-static HBITMAP32 hBmpCloseD = 0;
+static HBITMAP hBmpMinimize = 0;
+static HBITMAP hBmpMinimizeD = 0;
+static HBITMAP hBmpMaximize = 0;
+static HBITMAP hBmpMaximizeD = 0;
+static HBITMAP hBmpClose = 0;
+static HBITMAP hBmpCloseD = 0;
-static HBRUSH32 hShadeBrush = 0;
-static HMENU32 MENU_DefSysPopup = 0; /* Default system menu popup */
+static HBRUSH hShadeBrush = 0;
+static HMENU MENU_DefSysPopup = 0; /* Default system menu popup */
/* Use global popup window because there's no way 2 menus can
* be tracked at the same time. */
static WND* pTopPopupWnd = 0;
-static UINT32 uSubPWndLevel = 0;
+static UINT uSubPWndLevel = 0;
/* Flag set by EndMenu() to force an exit from menu tracking */
-static BOOL32 fEndMenu = FALSE;
+static BOOL fEndMenu = FALSE;
/***********************************************************************
@@ -183,7 +183,7 @@
dbg_decl_str(menu, 256);
if (mp) {
- UINT32 flags = mp->fType;
+ UINT flags = mp->fType;
int typ = MENU_ITEM_TYPE(flags);
dsprintf(menu, "{ ID=0x%x", mp->wID);
if (flags & MF_POPUP)
@@ -257,9 +257,9 @@
*
* Return the default system menu.
*/
-static HMENU32 MENU_CopySysPopup(void)
+static HMENU MENU_CopySysPopup(void)
{
- HMENU32 hMenu = LoadMenuIndirect32A(SYSRES_GetResPtr(SYSRES_MENU_SYSMENU));
+ HMENU hMenu = LoadMenuIndirectA(SYSRES_GetResPtr(SYSRES_MENU_SYSMENU));
if( hMenu ) {
POPUPMENU* menu = (POPUPMENU *) USER_HEAP_LIN_ADDR(hMenu);
@@ -285,23 +285,23 @@
* However, the real system menu handle is sometimes seen in the
* WM_MENUSELECT paramemters (and Word 6 likes it this way).
*/
-HMENU32 MENU_GetSysMenu( HWND32 hWnd, HMENU32 hPopupMenu )
+HMENU MENU_GetSysMenu( HWND hWnd, HMENU hPopupMenu )
{
- HMENU32 hMenu;
+ HMENU hMenu;
- if ((hMenu = CreateMenu32()))
+ if ((hMenu = CreateMenu()))
{
POPUPMENU *menu = (POPUPMENU*) USER_HEAP_LIN_ADDR(hMenu);
menu->wFlags = MF_SYSMENU;
menu->hWnd = hWnd;
- if (hPopupMenu == (HMENU32)(-1))
+ if (hPopupMenu == (HMENU)(-1))
hPopupMenu = MENU_CopySysPopup();
else if( !hPopupMenu ) hPopupMenu = MENU_DefSysPopup;
if (hPopupMenu)
{
- InsertMenu32A( hMenu, -1, MF_SYSMENU | MF_POPUP | MF_BYPOSITION, hPopupMenu, NULL );
+ InsertMenuA( hMenu, -1, MF_SYSMENU | MF_POPUP | MF_BYPOSITION, hPopupMenu, NULL );
menu->items[0].fType = MF_SYSMENU | MF_POPUP;
menu->items[0].fState = 0;
@@ -311,7 +311,7 @@
TRACE(menu,"GetSysMenu hMenu=%04x (%04x)\n", hMenu, hPopupMenu );
return hMenu;
}
- DestroyMenu32( hMenu );
+ DestroyMenu( hMenu );
}
ERR(menu, "failed to load system menu!\n");
return 0;
@@ -323,30 +323,30 @@
*
* Menus initialisation.
*/
-BOOL32 MENU_Init()
+BOOL MENU_Init()
{
- HBITMAP32 hBitmap;
+ HBITMAP hBitmap;
static unsigned char shade_bits[16] = { 0x55, 0, 0xAA, 0,
0x55, 0, 0xAA, 0,
0x55, 0, 0xAA, 0,
0x55, 0, 0xAA, 0 };
/* Load menu bitmaps */
- hStdCheck = LoadBitmap32A(0, MAKEINTRESOURCE32A(OBM_CHECK));
- hStdRadioCheck = LoadBitmap32A(0, MAKEINTRESOURCE32A(OBM_RADIOCHECK));
- hStdMnArrow = LoadBitmap32A(0, MAKEINTRESOURCE32A(OBM_MNARROW));
+ hStdCheck = LoadBitmapA(0, MAKEINTRESOURCEA(OBM_CHECK));
+ hStdRadioCheck = LoadBitmapA(0, MAKEINTRESOURCEA(OBM_RADIOCHECK));
+ hStdMnArrow = LoadBitmapA(0, MAKEINTRESOURCEA(OBM_MNARROW));
/* Load system buttons bitmaps */
- hBmpMinimize = LoadBitmap32A(0,MAKEINTRESOURCE32A(OBM_REDUCE));
- hBmpMinimizeD = LoadBitmap32A(0,MAKEINTRESOURCE32A(OBM_REDUCED));
- hBmpMaximize = LoadBitmap32A(0,MAKEINTRESOURCE32A(OBM_RESTORE));
- hBmpMaximizeD = LoadBitmap32A(0,MAKEINTRESOURCE32A(OBM_RESTORED));
- hBmpClose = LoadBitmap32A(0,MAKEINTRESOURCE32A(OBM_CLOSE));
- hBmpCloseD = LoadBitmap32A(0,MAKEINTRESOURCE32A(OBM_CLOSED));
+ hBmpMinimize = LoadBitmapA(0,MAKEINTRESOURCEA(OBM_REDUCE));
+ hBmpMinimizeD = LoadBitmapA(0,MAKEINTRESOURCEA(OBM_REDUCED));
+ hBmpMaximize = LoadBitmapA(0,MAKEINTRESOURCEA(OBM_RESTORE));
+ hBmpMaximizeD = LoadBitmapA(0,MAKEINTRESOURCEA(OBM_RESTORED));
+ hBmpClose = LoadBitmapA(0,MAKEINTRESOURCEA(OBM_CLOSE));
+ hBmpCloseD = LoadBitmapA(0,MAKEINTRESOURCEA(OBM_CLOSED));
if (hStdCheck)
{
- BITMAP32 bm;
- GetObject32A( hStdCheck, sizeof(bm), &bm );
+ BITMAP bm;
+ GetObjectA( hStdCheck, sizeof(bm), &bm );
check_bitmap_width = bm.bmWidth;
check_bitmap_height = bm.bmHeight;
} else
@@ -358,18 +358,18 @@
if (hStdMnArrow)
{
- BITMAP32 bm;
- GetObject32A( hStdMnArrow, sizeof(bm), &bm );
+ BITMAP bm;
+ GetObjectA( hStdMnArrow, sizeof(bm), &bm );
arrow_bitmap_width = bm.bmWidth;
arrow_bitmap_height = bm.bmHeight;
} else
return FALSE;
- if ((hBitmap = CreateBitmap32( 8, 8, 1, 1, shade_bits)))
+ if ((hBitmap = CreateBitmap( 8, 8, 1, 1, shade_bits)))
{
- if((hShadeBrush = CreatePatternBrush32( hBitmap )))
+ if((hShadeBrush = CreatePatternBrush( hBitmap )))
{
- DeleteObject32( hBitmap );
+ DeleteObject( hBitmap );
if ((MENU_DefSysPopup = MENU_CopySysPopup()))
return TRUE;
}
@@ -383,22 +383,22 @@
*
* Grey the appropriate items in System menu.
*/
-static void MENU_InitSysMenuPopup( HMENU32 hmenu, DWORD style, DWORD clsStyle )
+static void MENU_InitSysMenuPopup( HMENU hmenu, DWORD style, DWORD clsStyle )
{
- BOOL32 gray;
+ BOOL gray;
gray = !(style & WS_THICKFRAME) || (style & (WS_MAXIMIZE | WS_MINIMIZE));
- EnableMenuItem32( hmenu, SC_SIZE, (gray ? MF_GRAYED : MF_ENABLED) );
+ EnableMenuItem( hmenu, SC_SIZE, (gray ? MF_GRAYED : MF_ENABLED) );
gray = ((style & WS_MAXIMIZE) != 0);
- EnableMenuItem32( hmenu, SC_MOVE, (gray ? MF_GRAYED : MF_ENABLED) );
+ EnableMenuItem( hmenu, SC_MOVE, (gray ? MF_GRAYED : MF_ENABLED) );
gray = !(style & WS_MINIMIZEBOX) || (style & WS_MINIMIZE);
- EnableMenuItem32( hmenu, SC_MINIMIZE, (gray ? MF_GRAYED : MF_ENABLED) );
+ EnableMenuItem( hmenu, SC_MINIMIZE, (gray ? MF_GRAYED : MF_ENABLED) );
gray = !(style & WS_MAXIMIZEBOX) || (style & WS_MAXIMIZE);
- EnableMenuItem32( hmenu, SC_MAXIMIZE, (gray ? MF_GRAYED : MF_ENABLED) );
+ EnableMenuItem( hmenu, SC_MAXIMIZE, (gray ? MF_GRAYED : MF_ENABLED) );
gray = !(style & (WS_MAXIMIZE | WS_MINIMIZE));
- EnableMenuItem32( hmenu, SC_RESTORE, (gray ? MF_GRAYED : MF_ENABLED) );
+ EnableMenuItem( hmenu, SC_RESTORE, (gray ? MF_GRAYED : MF_ENABLED) );
gray = (clsStyle & CS_NOCLOSE) != 0;
- EnableMenuItem32( hmenu, SC_CLOSE, (gray ? MF_GRAYED : MF_ENABLED) );
+ EnableMenuItem( hmenu, SC_CLOSE, (gray ? MF_GRAYED : MF_ENABLED) );
}
@@ -409,11 +409,11 @@
*
*****************************************************************************/
-static UINT32 MENU_GetStartOfNextColumn(
- HMENU32 hMenu )
+static UINT MENU_GetStartOfNextColumn(
+ HMENU hMenu )
{
POPUPMENU *menu = (POPUPMENU *)USER_HEAP_LIN_ADDR(hMenu);
- UINT32 i = menu->FocusedItem + 1;
+ UINT i = menu->FocusedItem + 1;
if(!menu)
return NO_SELECTED_ITEM;
@@ -437,11 +437,11 @@
*
*****************************************************************************/
-static UINT32 MENU_GetStartOfPrevColumn(
- HMENU32 hMenu )
+static UINT MENU_GetStartOfPrevColumn(
+ HMENU hMenu )
{
POPUPMENU const *menu = (POPUPMENU *)USER_HEAP_LIN_ADDR(hMenu);
- UINT32 i;
+ UINT i;
if( !menu )
return NO_SELECTED_ITEM;
@@ -476,10 +476,10 @@
* Find a menu item. Return a pointer on the item, and modifies *hmenu
* in case the item was in a sub-menu.
*/
-static MENUITEM *MENU_FindItem( HMENU32 *hmenu, UINT32 *nPos, UINT32 wFlags )
+static MENUITEM *MENU_FindItem( HMENU *hmenu, UINT *nPos, UINT wFlags )
{
POPUPMENU *menu;
- UINT32 i;
+ UINT i;
if (!(menu = (POPUPMENU *) USER_HEAP_LIN_ADDR(*hmenu))) return NULL;
if (wFlags & MF_BYPOSITION)
@@ -499,7 +499,7 @@
}
else if (item->fType & MF_POPUP)
{
- HMENU32 hsubmenu = item->hSubMenu;
+ HMENU hsubmenu = item->hSubMenu;
MENUITEM *subitem = MENU_FindItem( &hsubmenu, nPos, wFlags );
if (subitem)
{
@@ -530,11 +530,11 @@
* an arbitrary system menu.
*/
static MENUITEM *MENU_FindItemByCoords( POPUPMENU *menu,
- POINT32 pt, UINT32 *pos )
+ POINT pt, UINT *pos )
{
MENUITEM *item;
WND *wndPtr;
- UINT32 i;
+ UINT i;
if (!(wndPtr = WIN_FindWndPtr( menu->hWnd ))) return NULL;
pt.x -= wndPtr->rectWindow.left;
@@ -559,15 +559,15 @@
* Find the menu item selected by a key press.
* Return item id, -1 if none, -2 if we should close the menu.
*/
-static UINT32 MENU_FindItemByKey( HWND32 hwndOwner, HMENU32 hmenu,
- UINT32 key, BOOL32 forceMenuChar )
+static UINT MENU_FindItemByKey( HWND hwndOwner, HMENU hmenu,
+ UINT key, BOOL forceMenuChar )
{
TRACE(menu,"\tlooking for '%c' in [%04x]\n", (char)key, (UINT16)hmenu );
- if (!IsMenu32( hmenu ))
+ if (!IsMenu( hmenu ))
{
WND* w = WIN_FindWndPtr(hwndOwner);
- hmenu = GetSubMenu32(w->hSysMenu, 0);
+ hmenu = GetSubMenu(w->hSysMenu, 0);
}
if (hmenu)
@@ -578,7 +578,7 @@
if( !forceMenuChar )
{
- UINT32 i;
+ UINT i;
key = toupper(key);
for (i = 0; i < menu->nItems; i++, item++)
@@ -595,12 +595,12 @@
}
}
}
- menuchar = SendMessage32A( hwndOwner, WM_MENUCHAR,
+ menuchar = SendMessageA( hwndOwner, WM_MENUCHAR,
MAKEWPARAM( key, menu->wFlags ), hmenu );
if (HIWORD(menuchar) == 2) return LOWORD(menuchar);
- if (HIWORD(menuchar) == 1) return (UINT32)(-2);
+ if (HIWORD(menuchar) == 1) return (UINT)(-2);
}
- return (UINT32)(-1);
+ return (UINT)(-1);
}
/***********************************************************************
* MENU_LoadMagicItem
@@ -608,7 +608,7 @@
* Load the bitmap associated with the magic menu item and its style
*/
-static HBITMAP32 MENU_LoadMagicItem(UINT32 id,BOOL32 hilite)
+static HBITMAP MENU_LoadMagicItem(UINT id,BOOL hilite)
{
// Magic menu item id's section
// These magic id's are used by windows to insert "standard" mdi
@@ -631,8 +631,8 @@
*
* Calculate the size of the menu item and store it in lpitem->rect.
*/
-static void MENU_CalcItemSize( HDC32 hdc, MENUITEM *lpitem, HWND32 hwndOwner,
- INT32 orgX, INT32 orgY, BOOL32 menuBar )
+static void MENU_CalcItemSize( HDC hdc, MENUITEM *lpitem, HWND hwndOwner,
+ INT orgX, INT orgY, BOOL menuBar )
{
DWORD dwSize;
char *p;
@@ -642,17 +642,17 @@
debug_print_menuitem("MENU_CalcItemSize: menuitem:", lpitem,
(menuBar ? " (MenuBar)" : ""));
- SetRect32( &lpitem->rect, orgX, orgY, orgX, orgY );
+ SetRect( &lpitem->rect, orgX, orgY, orgX, orgY );
if (lpitem->fType & MF_OWNERDRAW)
{
- MEASUREITEMSTRUCT32 mis;
+ MEASUREITEMSTRUCT mis;
mis.CtlType = ODT_MENU;
mis.itemID = lpitem->wID;
mis.itemData = (DWORD)lpitem->text;
mis.itemHeight = 16;
mis.itemWidth = 30;
- SendMessage32A( hwndOwner, WM_MEASUREITEM, 0, (LPARAM)&mis );
+ SendMessageA( hwndOwner, WM_MEASUREITEM, 0, (LPARAM)&mis );
lpitem->rect.bottom += mis.itemHeight;
lpitem->rect.right += mis.itemWidth;
TRACE(menu, "%08x %dx%d\n",
@@ -675,8 +675,8 @@
if (lpitem->fType & MF_BITMAP)
{
- BITMAP32 bm;
- HBITMAP32 resBmp = 0;
+ BITMAP bm;
+ HBITMAP resBmp = 0;
// Check if there is a magic menu item associated with this item
if((LOWORD((int)lpitem->text))<6)
@@ -685,9 +685,9 @@
(lpitem->fType & MF_HILITE));
}
else
- resBmp = (HBITMAP32)lpitem->text;
+ resBmp = (HBITMAP)lpitem->text;
- if (GetObject32A(resBmp, sizeof(bm), &bm ))
+ if (GetObjectA(resBmp, sizeof(bm), &bm ))
{
lpitem->rect.right += bm.bmWidth;
lpitem->rect.bottom += bm.bmHeight;
@@ -702,7 +702,7 @@
if (IS_STRING_ITEM( lpitem->fType ))
{
- dwSize = GetTextExtent( hdc, lpitem->text, strlen(lpitem->text) );
+ dwSize = GetTextExtent16( hdc, lpitem->text, strlen(lpitem->text) );
lpitem->rect.right += LOWORD(dwSize);
if (TWEAK_WineLook == WIN31_LOOK)
lpitem->rect.bottom += MAX( HIWORD(dwSize), SYSMETRICS_CYMENU );
@@ -715,7 +715,7 @@
{
/* Item contains a tab (only meaningful in popup menus) */
lpitem->xTab = check_bitmap_width + MENU_TAB_SPACE +
- LOWORD( GetTextExtent( hdc, lpitem->text,
+ LOWORD( GetTextExtent16( hdc, lpitem->text,
(int)(p - lpitem->text) ));
lpitem->rect.right += MENU_TAB_SPACE;
}
@@ -735,16 +735,16 @@
*
* Calculate the size of a popup menu.
*/
-static void MENU_PopupMenuCalcSize( LPPOPUPMENU lppop, HWND32 hwndOwner )
+static void MENU_PopupMenuCalcSize( LPPOPUPMENU lppop, HWND hwndOwner )
{
MENUITEM *lpitem;
- HDC32 hdc;
+ HDC hdc;
int start, i;
int orgX, orgY, maxX, maxTab, maxTabWidth;
lppop->Width = lppop->Height = 0;
if (lppop->nItems == 0) return;
- hdc = GetDC32( 0 );
+ hdc = GetDC( 0 );
start = 0;
maxX = SYSMETRICS_CXBORDER;
while (start < lppop->nItems)
@@ -791,7 +791,7 @@
lppop->Height++;
lppop->Width = maxX;
- ReleaseDC32( 0, hdc );
+ ReleaseDC( 0, hdc );
}
@@ -804,8 +804,8 @@
*
* Calculate the size of the menu bar.
*/
-static void MENU_MenuBarCalcSize( HDC32 hdc, LPRECT32 lprect,
- LPPOPUPMENU lppop, HWND32 hwndOwner )
+static void MENU_MenuBarCalcSize( HDC hdc, LPRECT lprect,
+ LPPOPUPMENU lppop, HWND hwndOwner )
{
MENUITEM *lpitem;
int start, i, orgX, orgY, maxY, helpPos;
@@ -876,16 +876,16 @@
*
* Draw a single menu item.
*/
-static void MENU_DrawMenuItem( HWND32 hwnd, HDC32 hdc, MENUITEM *lpitem,
- UINT32 height, BOOL32 menuBar, UINT32 odaction )
+static void MENU_DrawMenuItem( HWND hwnd, HDC hdc, MENUITEM *lpitem,
+ UINT height, BOOL menuBar, UINT odaction )
{
- RECT32 rect;
+ RECT rect;
debug_print_menuitem("MENU_DrawMenuItem: ", lpitem, "");
if (lpitem->fType & MF_SYSMENU)
{
- if( !IsIconic32(hwnd) ) {
+ if( !IsIconic(hwnd) ) {
if (TWEAK_WineLook > WIN31_LOOK)
NC_DrawSysButton95( hwnd, hdc,
lpitem->fState &
@@ -901,7 +901,7 @@
if (lpitem->fType & MF_OWNERDRAW)
{
- DRAWITEMSTRUCT32 dis;
+ DRAWITEMSTRUCT dis;
dis.CtlType = ODT_MENU;
dis.itemID = lpitem->wID;
@@ -919,7 +919,7 @@
dis.itemState, dis.itemAction, dis.hwndItem, dis.hDC,
dis.rcItem.left, dis.rcItem.top, dis.rcItem.right,
dis.rcItem.bottom );
- SendMessage32A( GetWindow32(hwnd,GW_OWNER), WM_DRAWITEM, 0, (LPARAM)&dis );
+ SendMessageA( GetWindow(hwnd,GW_OWNER), WM_DRAWITEM, 0, (LPARAM)&dis );
return;
}
@@ -942,11 +942,11 @@
}
if ((lpitem->fState & MF_HILITE) && !(lpitem->fType & MF_BITMAP) )
- FillRect32( hdc, &rect, GetSysColorBrush32(COLOR_HIGHLIGHT) );
+ FillRect( hdc, &rect, GetSysColorBrush(COLOR_HIGHLIGHT) );
else
- FillRect32( hdc, &rect, GetSysColorBrush32(COLOR_MENU) );
+ FillRect( hdc, &rect, GetSysColorBrush(COLOR_MENU) );
- SetBkMode32( hdc, TRANSPARENT );
+ SetBkMode( hdc, TRANSPARENT );
/* Draw the separator bar (if any) */
@@ -954,31 +954,31 @@
{
/* vertical separator */
if (TWEAK_WineLook > WIN31_LOOK) {
- RECT32 rc = rect;
+ RECT rc = rect;
rc.top = 3;
rc.bottom = height - 3;
- DrawEdge32 (hdc, &rc, EDGE_ETCHED, BF_LEFT);
+ DrawEdge (hdc, &rc, EDGE_ETCHED, BF_LEFT);
}
else {
- SelectObject32( hdc, GetSysColorPen32(COLOR_WINDOWFRAME) );
- MoveTo( hdc, rect.left, 0 );
- LineTo32( hdc, rect.left, height );
+ SelectObject( hdc, GetSysColorPen(COLOR_WINDOWFRAME) );
+ MoveTo16( hdc, rect.left, 0 );
+ LineTo( hdc, rect.left, height );
}
}
if (lpitem->fType & MF_SEPARATOR)
{
/* horizontal separator */
if (TWEAK_WineLook > WIN31_LOOK) {
- RECT32 rc = rect;
+ RECT rc = rect;
rc.left++;
rc.right--;
rc.top += SEPARATOR_HEIGHT / 2;
- DrawEdge32 (hdc, &rc, EDGE_ETCHED, BF_TOP);
+ DrawEdge (hdc, &rc, EDGE_ETCHED, BF_TOP);
}
else {
- SelectObject32( hdc, GetSysColorPen32(COLOR_WINDOWFRAME) );
- MoveTo( hdc, rect.left, rect.top + SEPARATOR_HEIGHT/2 );
- LineTo32( hdc, rect.right, rect.top + SEPARATOR_HEIGHT/2 );
+ SelectObject( hdc, GetSysColorPen(COLOR_WINDOWFRAME) );
+ MoveTo16( hdc, rect.left, rect.top + SEPARATOR_HEIGHT/2 );
+ LineTo( hdc, rect.right, rect.top + SEPARATOR_HEIGHT/2 );
}
return;
@@ -989,23 +989,23 @@
if ((lpitem->fState & MF_HILITE) && !(lpitem->fType & MF_BITMAP) )
{
if (lpitem->fState & MF_GRAYED)
- SetTextColor32( hdc, GetSysColor32( COLOR_GRAYTEXT ) );
+ SetTextColor( hdc, GetSysColor( COLOR_GRAYTEXT ) );
else
- SetTextColor32( hdc, GetSysColor32( COLOR_HIGHLIGHTTEXT ) );
- SetBkColor32( hdc, GetSysColor32( COLOR_HIGHLIGHT ) );
+ SetTextColor( hdc, GetSysColor( COLOR_HIGHLIGHTTEXT ) );
+ SetBkColor( hdc, GetSysColor( COLOR_HIGHLIGHT ) );
}
else
{
if (lpitem->fState & MF_GRAYED)
- SetTextColor32( hdc, GetSysColor32( COLOR_GRAYTEXT ) );
+ SetTextColor( hdc, GetSysColor( COLOR_GRAYTEXT ) );
else
- SetTextColor32( hdc, GetSysColor32( COLOR_MENUTEXT ) );
- SetBkColor32( hdc, GetSysColor32( COLOR_MENU ) );
+ SetTextColor( hdc, GetSysColor( COLOR_MENUTEXT ) );
+ SetBkColor( hdc, GetSysColor( COLOR_MENU ) );
}
if (!menuBar)
{
- INT32 y = rect.top + rect.bottom;
+ INT y = rect.top + rect.bottom;
/* Draw the check mark
*
@@ -1015,39 +1015,39 @@
if (lpitem->fState & MF_CHECKED)
{
- HBITMAP32 bm =
+ HBITMAP bm =
lpitem->hCheckBit ? lpitem->hCheckBit :
((lpitem->fType & MFT_RADIOCHECK)
? hStdRadioCheck : hStdCheck);
- HDC32 hdcMem = CreateCompatibleDC32( hdc );
+ HDC hdcMem = CreateCompatibleDC( hdc );
- SelectObject32( hdcMem, bm );
- BitBlt32( hdc, rect.left, (y - check_bitmap_height) / 2,
+ SelectObject( hdcMem, bm );
+ BitBlt( hdc, rect.left, (y - check_bitmap_height) / 2,
check_bitmap_width, check_bitmap_height,
hdcMem, 0, 0, SRCCOPY );
- DeleteDC32( hdcMem );
+ DeleteDC( hdcMem );
} else if (lpitem->hUnCheckBit) {
- HDC32 hdcMem = CreateCompatibleDC32( hdc );
+ HDC hdcMem = CreateCompatibleDC( hdc );
- SelectObject32( hdcMem, lpitem->hUnCheckBit );
- BitBlt32( hdc, rect.left, (y - check_bitmap_height) / 2,
+ SelectObject( hdcMem, lpitem->hUnCheckBit );
+ BitBlt( hdc, rect.left, (y - check_bitmap_height) / 2,
check_bitmap_width, check_bitmap_height,
hdcMem, 0, 0, SRCCOPY );
- DeleteDC32( hdcMem );
+ DeleteDC( hdcMem );
}
/* Draw the popup-menu arrow */
if (lpitem->fType & MF_POPUP)
{
- HDC32 hdcMem = CreateCompatibleDC32( hdc );
+ HDC hdcMem = CreateCompatibleDC( hdc );
- SelectObject32( hdcMem, hStdMnArrow );
- BitBlt32( hdc, rect.right - arrow_bitmap_width - 1,
+ SelectObject( hdcMem, hStdMnArrow );
+ BitBlt( hdc, rect.right - arrow_bitmap_width - 1,
(y - arrow_bitmap_height) / 2,
arrow_bitmap_width, arrow_bitmap_height,
hdcMem, 0, 0, SRCCOPY );
- DeleteDC32( hdcMem );
+ DeleteDC( hdcMem );
}
rect.left += check_bitmap_width;
@@ -1058,9 +1058,9 @@
if (lpitem->fType & MF_BITMAP)
{
- HBITMAP32 resBmp = 0;
+ HBITMAP resBmp = 0;
- HDC32 hdcMem = CreateCompatibleDC32( hdc );
+ HDC hdcMem = CreateCompatibleDC( hdc );
// Check if there is a magic menu item associated with this item
// and load the appropriate bitmap
@@ -1070,12 +1070,12 @@
(lpitem->fState & MF_HILITE));
}
else
- resBmp = (HBITMAP32)lpitem->text;
+ resBmp = (HBITMAP)lpitem->text;
- SelectObject32(hdcMem,resBmp );
- BitBlt32( hdc, rect.left, rect.top+3, rect.right - rect.left+3,
+ SelectObject(hdcMem,resBmp );
+ BitBlt( hdc, rect.left, rect.top+3, rect.right - rect.left+3,
rect.bottom - rect.top, hdcMem, 0, 0, SRCCOPY );
- DeleteDC32( hdcMem );
+ DeleteDC( hdcMem );
return;
@@ -1099,7 +1099,7 @@
}
if((TWEAK_WineLook == WIN31_LOOK) || !(lpitem->fState & MF_GRAYED)) {
- DrawText32A( hdc, lpitem->text, i, &rect,
+ DrawTextA( hdc, lpitem->text, i, &rect,
DT_LEFT | DT_VCENTER | DT_SINGLELINE );
}
else {
@@ -1109,16 +1109,16 @@
++rect.top;
++rect.right;
++rect.bottom;
- SetTextColor32(hdc, RGB(0xff, 0xff, 0xff));
- DrawText32A( hdc, lpitem->text, i, &rect,
+ SetTextColor(hdc, RGB(0xff, 0xff, 0xff));
+ DrawTextA( hdc, lpitem->text, i, &rect,
DT_LEFT | DT_VCENTER | DT_SINGLELINE );
--rect.left;
--rect.top;
--rect.right;
--rect.bottom;
}
- SetTextColor32(hdc, RGB(0x80, 0x80, 0x80));
- DrawText32A( hdc, lpitem->text, i, &rect,
+ SetTextColor(hdc, RGB(0x80, 0x80, 0x80));
+ DrawTextA( hdc, lpitem->text, i, &rect,
DT_LEFT | DT_VCENTER | DT_SINGLELINE );
}
@@ -1127,10 +1127,10 @@
if (lpitem->text[i] == '\t')
{
rect.left = lpitem->xTab;
- DrawText32A( hdc, lpitem->text + i + 1, -1, &rect,
+ DrawTextA( hdc, lpitem->text + i + 1, -1, &rect,
DT_LEFT | DT_VCENTER | DT_SINGLELINE );
}
- else DrawText32A( hdc, lpitem->text + i + 1, -1, &rect,
+ else DrawTextA( hdc, lpitem->text + i + 1, -1, &rect,
DT_RIGHT | DT_VCENTER | DT_SINGLELINE );
}
}
@@ -1142,51 +1142,51 @@
*
* Paint a popup menu.
*/
-static void MENU_DrawPopupMenu( HWND32 hwnd, HDC32 hdc, HMENU32 hmenu )
+static void MENU_DrawPopupMenu( HWND hwnd, HDC hdc, HMENU hmenu )
{
- HBRUSH32 hPrevBrush = 0;
- RECT32 rect;
+ HBRUSH hPrevBrush = 0;
+ RECT rect;
- GetClientRect32( hwnd, &rect );
+ GetClientRect( hwnd, &rect );
/* if(!TWEAK_Win95Look) { */
rect.bottom -= POPUP_YSHADE * SYSMETRICS_CYBORDER;
rect.right -= POPUP_XSHADE * SYSMETRICS_CXBORDER;
/* } */
- if((hPrevBrush = SelectObject32( hdc, GetSysColorBrush32(COLOR_MENU) )))
+ if((hPrevBrush = SelectObject( hdc, GetSysColorBrush(COLOR_MENU) )))
{
- HPEN32 hPrevPen;
+ HPEN hPrevPen;
- Rectangle32( hdc, rect.left, rect.top, rect.right, rect.bottom );
+ Rectangle( hdc, rect.left, rect.top, rect.right, rect.bottom );
- hPrevPen = SelectObject32( hdc, GetStockObject32( NULL_PEN ) );
+ hPrevPen = SelectObject( hdc, GetStockObject( NULL_PEN ) );
if( hPrevPen )
{
- INT32 ropPrev, i;
+ INT ropPrev, i;
POPUPMENU *menu;
/* draw 3-d shade */
if(TWEAK_WineLook == WIN31_LOOK) {
- SelectObject32( hdc, hShadeBrush );
- SetBkMode32( hdc, TRANSPARENT );
- ropPrev = SetROP232( hdc, R2_MASKPEN );
+ SelectObject( hdc, hShadeBrush );
+ SetBkMode( hdc, TRANSPARENT );
+ ropPrev = SetROP2( hdc, R2_MASKPEN );
i = rect.right; /* why SetBrushOrg() doesn't? */
- PatBlt32( hdc, i & 0xfffffffe,
+ PatBlt( hdc, i & 0xfffffffe,
rect.top + POPUP_YSHADE*SYSMETRICS_CYBORDER,
i%2 + POPUP_XSHADE*SYSMETRICS_CXBORDER,
rect.bottom - rect.top, 0x00a000c9 );
i = rect.bottom;
- PatBlt32( hdc, rect.left + POPUP_XSHADE*SYSMETRICS_CXBORDER,
+ PatBlt( hdc, rect.left + POPUP_XSHADE*SYSMETRICS_CXBORDER,
i & 0xfffffffe,rect.right - rect.left,
i%2 + POPUP_YSHADE*SYSMETRICS_CYBORDER, 0x00a000c9 );
- SelectObject32( hdc, hPrevPen );
- SelectObject32( hdc, hPrevBrush );
- SetROP232( hdc, ropPrev );
+ SelectObject( hdc, hPrevPen );
+ SelectObject( hdc, hPrevBrush );
+ SetROP2( hdc, ropPrev );
}
else
- DrawEdge32 (hdc, &rect, EDGE_RAISED, BF_RECT);
+ DrawEdge (hdc, &rect, EDGE_RAISED, BF_RECT);
/* draw menu items */
@@ -1194,14 +1194,14 @@
if (menu && menu->nItems)
{
MENUITEM *item;
- UINT32 u;
+ UINT u;
for (u = menu->nItems, item = menu->items; u > 0; u--, item++)
MENU_DrawMenuItem( hwnd, hdc, item, menu->Height, FALSE,
ODA_DRAWENTIRE );
}
- } else SelectObject32( hdc, hPrevBrush );
+ } else SelectObject( hdc, hPrevBrush );
}
}
@@ -1211,11 +1211,11 @@
*
* Paint a menu bar. Returns the height of the menu bar.
*/
-UINT32 MENU_DrawMenuBar( HDC32 hDC, LPRECT32 lprect, HWND32 hwnd,
- BOOL32 suppress_draw)
+UINT MENU_DrawMenuBar( HDC hDC, LPRECT lprect, HWND hwnd,
+ BOOL suppress_draw)
{
LPPOPUPMENU lppop;
- UINT32 i;
+ UINT i;
WND *wndPtr = WIN_FindWndPtr( hwnd );
lppop = (LPPOPUPMENU) USER_HEAP_LIN_ADDR( (HMENU16)wndPtr->wIDmenu );
@@ -1226,17 +1226,17 @@
lprect->bottom = lprect->top + lppop->Height;
if (suppress_draw) return lppop->Height;
- FillRect32(hDC, lprect, GetSysColorBrush32(COLOR_MENU) );
+ FillRect(hDC, lprect, GetSysColorBrush(COLOR_MENU) );
if (TWEAK_WineLook == WIN31_LOOK) {
- SelectObject32( hDC, GetSysColorPen32(COLOR_WINDOWFRAME) );
- MoveTo( hDC, lprect->left, lprect->bottom );
- LineTo32( hDC, lprect->right, lprect->bottom );
+ SelectObject( hDC, GetSysColorPen(COLOR_WINDOWFRAME) );
+ MoveTo16( hDC, lprect->left, lprect->bottom );
+ LineTo( hDC, lprect->right, lprect->bottom );
}
else {
- SelectObject32( hDC, GetSysColorPen32(COLOR_3DFACE));
- MoveTo( hDC, lprect->left, lprect->bottom );
- LineTo32( hDC, lprect->right, lprect->bottom );
+ SelectObject( hDC, GetSysColorPen(COLOR_3DFACE));
+ MoveTo16( hDC, lprect->left, lprect->bottom );
+ LineTo( hDC, lprect->right, lprect->bottom );
}
if (lppop->nItems == 0) return SYSMETRICS_CYMENU;
@@ -1252,7 +1252,7 @@
/***********************************************************************
* MENU_PatchResidentPopup
*/
-BOOL32 MENU_PatchResidentPopup( HQUEUE16 checkQueue, WND* checkWnd )
+BOOL MENU_PatchResidentPopup( HQUEUE16 checkQueue, WND* checkWnd )
{
if( pTopPopupWnd )
{
@@ -1307,8 +1307,8 @@
*
* Display a popup menu.
*/
-static BOOL32 MENU_ShowPopup( HWND32 hwndOwner, HMENU32 hmenu, UINT32 id,
- INT32 x, INT32 y, INT32 xanchor, INT32 yanchor )
+static BOOL MENU_ShowPopup( HWND hwndOwner, HMENU hmenu, UINT id,
+ INT x, INT y, INT xanchor, INT yanchor )
{
POPUPMENU *menu;
WND *wndOwner = NULL;
@@ -1322,7 +1322,7 @@
if( (wndOwner = WIN_FindWndPtr( hwndOwner )) )
{
- UINT32 width, height;
+ UINT width, height;
MENU_PopupMenuCalcSize( menu, hwndOwner );
@@ -1357,7 +1357,7 @@
{
assert( uSubPWndLevel == 0 );
- pTopPopupWnd = WIN_FindWndPtr(CreateWindow32A( POPUPMENU_CLASS_ATOM, NULL,
+ pTopPopupWnd = WIN_FindWndPtr(CreateWindowA( POPUPMENU_CLASS_ATOM, NULL,
WS_POPUP, x, y, width, height,
hwndOwner, 0, wndOwner->hInstance,
(LPVOID)hmenu ));
@@ -1369,7 +1369,7 @@
{
/* create a new window for the submenu */
- menu->hWnd = CreateWindow32A( POPUPMENU_CLASS_ATOM, NULL,
+ menu->hWnd = CreateWindowA( POPUPMENU_CLASS_ATOM, NULL,
WS_POPUP, x, y, width, height,
menu->hWnd, 0, wndOwner->hInstance,
(LPVOID)hmenu );
@@ -1384,7 +1384,7 @@
/* adjust its size */
- SetWindowPos32( menu->hWnd, 0, x, y, width, height,
+ SetWindowPos( menu->hWnd, 0, x, y, width, height,
SWP_NOACTIVATE | SWP_NOZORDER | SWP_NOREDRAW);
}
@@ -1392,9 +1392,9 @@
/* Display the window */
- SetWindowPos32( menu->hWnd, HWND_TOP, 0, 0, 0, 0,
+ SetWindowPos( menu->hWnd, HWND_TOP, 0, 0, 0, 0,
SWP_SHOWWINDOW | SWP_NOSIZE | SWP_NOMOVE | SWP_NOACTIVATE );
- UpdateWindow32( menu->hWnd );
+ UpdateWindow( menu->hWnd );
return TRUE;
}
return FALSE;
@@ -1404,11 +1404,11 @@
/***********************************************************************
* MENU_SelectItem
*/
-static void MENU_SelectItem( HWND32 hwndOwner, HMENU32 hmenu, UINT32 wIndex,
- BOOL32 sendMenuSelect )
+static void MENU_SelectItem( HWND hwndOwner, HMENU hmenu, UINT wIndex,
+ BOOL sendMenuSelect )
{
LPPOPUPMENU lppop;
- HDC32 hdc;
+ HDC hdc;
lppop = (POPUPMENU *) USER_HEAP_LIN_ADDR( hmenu );
if (!lppop->nItems) return;
@@ -1418,8 +1418,8 @@
wIndex = NO_SELECTED_ITEM;
if (lppop->FocusedItem == wIndex) return;
- if (lppop->wFlags & MF_POPUP) hdc = GetDC32( lppop->hWnd );
- else hdc = GetDCEx32( lppop->hWnd, 0, DCX_CACHE | DCX_WINDOW);
+ if (lppop->wFlags & MF_POPUP) hdc = GetDC( lppop->hWnd );
+ else hdc = GetDCEx( lppop->hWnd, 0, DCX_CACHE | DCX_WINDOW);
/* Clear previous highlighted item */
if (lppop->FocusedItem != NO_SELECTED_ITEM)
@@ -1450,7 +1450,7 @@
SendMessage16( hwndOwner, WM_MENUSELECT, hmenu,
MAKELONG( lppop->wFlags | MF_MOUSESELECT, hmenu ) );
}
- ReleaseDC32( lppop->hWnd, hdc );
+ ReleaseDC( lppop->hWnd, hdc );
}
@@ -1461,9 +1461,9 @@
* If there is no selection then it should select the last item if
* offset is ITEM_PREV or the first item if offset is ITEM_NEXT.
*/
-static void MENU_MoveSelection( HWND32 hwndOwner, HMENU32 hmenu, INT32 offset )
+static void MENU_MoveSelection( HWND hwndOwner, HMENU hmenu, INT offset )
{
- INT32 i;
+ INT i;
POPUPMENU *menu;
menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hmenu );
@@ -1497,7 +1497,7 @@
* Set an item flags, id and text ptr. Called by InsertMenu() and
* ModifyMenu().
*/
-static BOOL32 MENU_SetItemData( MENUITEM *item, UINT32 flags, UINT32 id,
+static BOOL MENU_SetItemData( MENUITEM *item, UINT flags, UINT id,
LPCSTR str )
{
LPSTR prevText = IS_STRING_ITEM(item->fType) ? item->text : NULL;
@@ -1524,7 +1524,7 @@
item->text = text;
}
}
- else if (flags & MF_BITMAP) item->text = (LPSTR)(HBITMAP32)LOWORD(str);
+ else if (flags & MF_BITMAP) item->text = (LPSTR)(HBITMAP)LOWORD(str);
else item->text = NULL;
if (flags & MF_OWNERDRAW)
@@ -1533,7 +1533,7 @@
item->dwItemData = 0;
if ((item->fType & MF_POPUP) && (flags & MF_POPUP) && (item->hSubMenu != id) )
- DestroyMenu32( item->hSubMenu ); /* ModifyMenu() spec */
+ DestroyMenu( item->hSubMenu ); /* ModifyMenu() spec */
if (flags & MF_POPUP)
{
@@ -1576,7 +1576,7 @@
*
* Insert a new item into a menu.
*/
-static MENUITEM *MENU_InsertItem( HMENU32 hMenu, UINT32 pos, UINT32 flags )
+static MENUITEM *MENU_InsertItem( HMENU hMenu, UINT pos, UINT flags )
{
MENUITEM *newItems;
POPUPMENU *menu;
@@ -1591,7 +1591,7 @@
/* Find where to insert new item */
if ((flags & MF_BYPOSITION) &&
- ((pos == (UINT32)-1) || (pos == menu->nItems)))
+ ((pos == (UINT)-1) || (pos == menu->nItems)))
{
/* Special case: append to menu */
/* Some programs specify the menu length to do that */
@@ -1642,7 +1642,7 @@
* Parse a standard menu resource and add items to the menu.
* Return a pointer to the end of the resource.
*/
-static LPCSTR MENU_ParseResource( LPCSTR res, HMENU32 hMenu, BOOL32 unicode )
+static LPCSTR MENU_ParseResource( LPCSTR res, HMENU hMenu, BOOL unicode )
{
WORD flags, id = 0;
LPCSTR str;
@@ -1660,20 +1660,20 @@
ERR(menu, "not a string item %04x\n", flags );
str = res;
if (!unicode) res += strlen(str) + 1;
- else res += (lstrlen32W((LPCWSTR)str) + 1) * sizeof(WCHAR);
+ else res += (lstrlenW((LPCWSTR)str) + 1) * sizeof(WCHAR);
if (flags & MF_POPUP)
{
- HMENU32 hSubMenu = CreatePopupMenu32();
+ HMENU hSubMenu = CreatePopupMenu();
if (!hSubMenu) return NULL;
if (!(res = MENU_ParseResource( res, hSubMenu, unicode )))
return NULL;
- if (!unicode) AppendMenu32A( hMenu, flags, (UINT32)hSubMenu, str );
- else AppendMenu32W( hMenu, flags, (UINT32)hSubMenu, (LPCWSTR)str );
+ if (!unicode) AppendMenuA( hMenu, flags, (UINT)hSubMenu, str );
+ else AppendMenuW( hMenu, flags, (UINT)hSubMenu, (LPCWSTR)str );
}
else /* Not a popup */
{
- if (!unicode) AppendMenu32A( hMenu, flags, id, *str ? str : NULL );
- else AppendMenu32W( hMenu, flags, id,
+ if (!unicode) AppendMenuA( hMenu, flags, id, *str ? str : NULL );
+ else AppendMenuW( hMenu, flags, id,
*(LPCWSTR)str ? (LPCWSTR)str : NULL );
}
} while (!(flags & MF_END));
@@ -1687,11 +1687,11 @@
* Parse an extended menu resource and add items to the menu.
* Return a pointer to the end of the resource.
*/
-static LPCSTR MENUEX_ParseResource( LPCSTR res, HMENU32 hMenu)
+static LPCSTR MENUEX_ParseResource( LPCSTR res, HMENU hMenu)
{
WORD resinfo;
do {
- MENUITEMINFO32W mii;
+ MENUITEMINFOW mii;
mii.cbSize = sizeof(mii);
mii.fMask = MIIM_STATE | MIIM_ID | MIIM_TYPE;
@@ -1706,7 +1706,7 @@
/* Align the text on a word boundary. */
res += (~((int)res - 1)) & 1;
mii.dwTypeData = (LPWSTR) res;
- res += (1 + lstrlen32W(mii.dwTypeData)) * sizeof(WCHAR);
+ res += (1 + lstrlenW(mii.dwTypeData)) * sizeof(WCHAR);
/* Align the following fields on a dword boundary. */
res += (~((int)res - 1)) & 3;
@@ -1722,17 +1722,17 @@
if (resinfo & 1) { /* Pop-up? */
DWORD helpid = GET_DWORD(res); /* FIXME: use this. */
res += sizeof(DWORD);
- mii.hSubMenu = CreatePopupMenu32();
+ mii.hSubMenu = CreatePopupMenu();
if (!mii.hSubMenu)
return NULL;
if (!(res = MENUEX_ParseResource(res, mii.hSubMenu))) {
- DestroyMenu32(mii.hSubMenu);
+ DestroyMenu(mii.hSubMenu);
return NULL;
}
mii.fMask |= MIIM_SUBMENU;
mii.fType |= MF_POPUP;
}
- InsertMenuItem32W(hMenu, -1, MF_BYPOSITION, &mii);
+ InsertMenuItemW(hMenu, -1, MF_BYPOSITION, &mii);
} while (!(resinfo & MF_END));
return res;
}
@@ -1743,7 +1743,7 @@
*
* Return the handle of the selected sub-popup menu (if any).
*/
-static HMENU32 MENU_GetSubPopup( HMENU32 hmenu )
+static HMENU MENU_GetSubPopup( HMENU hmenu )
{
POPUPMENU *menu;
MENUITEM *item;
@@ -1764,14 +1764,14 @@
*
* Hide the sub-popup menus of this menu.
*/
-static void MENU_HideSubPopups( HWND32 hwndOwner, HMENU32 hmenu,
- BOOL32 sendMenuSelect )
+static void MENU_HideSubPopups( HWND hwndOwner, HMENU hmenu,
+ BOOL sendMenuSelect )
{
POPUPMENU *menu = (POPUPMENU*) USER_HEAP_LIN_ADDR( hmenu );;
if (menu && uSubPWndLevel)
{
- HMENU32 hsubmenu;
+ HMENU hsubmenu;
POPUPMENU *submenu;
MENUITEM *item;
@@ -1790,12 +1790,12 @@
if (submenu->hWnd == pTopPopupWnd->hwndSelf )
{
- ShowWindow32( submenu->hWnd, SW_HIDE );
+ ShowWindow( submenu->hWnd, SW_HIDE );
uSubPWndLevel = 0;
}
else
{
- DestroyWindow32( submenu->hWnd );
+ DestroyWindow( submenu->hWnd );
submenu->hWnd = 0;
}
}
@@ -1808,14 +1808,14 @@
* Display the sub-menu of the selected item of this menu.
* Return the handle of the submenu, or hmenu if no submenu to display.
*/
-static HMENU32 MENU_ShowSubPopup( HWND32 hwndOwner, HMENU32 hmenu,
- BOOL32 selectFirst )
+static HMENU MENU_ShowSubPopup( HWND hwndOwner, HMENU hmenu,
+ BOOL selectFirst )
{
- RECT32 rect;
+ RECT rect;
POPUPMENU *menu;
MENUITEM *item;
WND *wndPtr;
- HDC32 hdc;
+ HDC hdc;
if (!(menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hmenu ))) return hmenu;
@@ -1838,11 +1838,11 @@
/* correct item if modified as a reaction to WM_INITMENUPOPUP-message */
if (!(item->fState & MF_HILITE))
{
- if (menu->wFlags & MF_POPUP) hdc = GetDC32( menu->hWnd );
- else hdc = GetDCEx32( menu->hWnd, 0, DCX_CACHE | DCX_WINDOW);
+ if (menu->wFlags & MF_POPUP) hdc = GetDC( menu->hWnd );
+ else hdc = GetDCEx( menu->hWnd, 0, DCX_CACHE | DCX_WINDOW);
item->fState |= MF_HILITE;
MENU_DrawMenuItem( menu->hWnd, hdc, item, menu->Height, !(menu->wFlags & MF_POPUP), ODA_DRAWENTIRE );
- ReleaseDC32( menu->hWnd, hdc );
+ ReleaseDC( menu->hWnd, hdc );
}
if (!item->rect.top && !item->rect.left && !item->rect.bottom && !item->rect.right)
item->rect = rect;
@@ -1888,32 +1888,32 @@
*
* Walks menu chain trying to find a menu pt maps to.
*/
-static HMENU32 MENU_PtMenu( HMENU32 hMenu, POINT16 pt )
+static HMENU MENU_PtMenu( HMENU hMenu, POINT16 pt )
{
POPUPMENU *menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hMenu );
- register UINT32 ht = menu->FocusedItem;
+ register UINT ht = menu->FocusedItem;
/* try subpopup first (if any) */
ht = (ht != NO_SELECTED_ITEM &&
(menu->items[ht].fType & MF_POPUP) &&
(menu->items[ht].fState & MF_MOUSESELECT))
- ? (UINT32) MENU_PtMenu(menu->items[ht].hSubMenu, pt) : 0;
+ ? (UINT) MENU_PtMenu(menu->items[ht].hSubMenu, pt) : 0;
if( !ht ) /* check the current window (avoiding WM_HITTEST) */
{
- ht = (UINT32)NC_HandleNCHitTest( menu->hWnd, pt );
+ ht = (UINT)NC_HandleNCHitTest( menu->hWnd, pt );
if( menu->wFlags & MF_POPUP )
- ht = (ht != (UINT32)HTNOWHERE &&
- ht != (UINT32)HTERROR) ? (UINT32)hMenu : 0;
+ ht = (ht != (UINT)HTNOWHERE &&
+ ht != (UINT)HTERROR) ? (UINT)hMenu : 0;
else
{
WND* wndPtr = WIN_FindWndPtr(menu->hWnd);
- ht = ( ht == HTSYSMENU ) ? (UINT32)(wndPtr->hSysMenu)
- : ( ht == HTMENU ) ? (UINT32)(wndPtr->wIDmenu) : 0;
+ ht = ( ht == HTSYSMENU ) ? (UINT)(wndPtr->hSysMenu)
+ : ( ht == HTMENU ) ? (UINT)(wndPtr->wIDmenu) : 0;
}
}
- return (HMENU32)ht;
+ return (HMENU)ht;
}
/***********************************************************************
* MENU_ExecFocusedItem
@@ -1922,7 +1922,7 @@
* Return the wID of the executed item. Otherwise, zero indicating
* that no menu item wase executed;
*/
-static INT32 MENU_ExecFocusedItem( MTRACKER* pmt, HMENU32 hMenu )
+static INT MENU_ExecFocusedItem( MTRACKER* pmt, HMENU hMenu )
{
MENUITEM *item;
POPUPMENU *menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hMenu );
@@ -1963,7 +1963,7 @@
*
* Helper function for menu navigation routines.
*/
-static void MENU_SwitchTracking( MTRACKER* pmt, HMENU32 hPtMenu, UINT32 id )
+static void MENU_SwitchTracking( MTRACKER* pmt, HMENU hPtMenu, UINT id )
{
POPUPMENU *ptmenu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hPtMenu );
POPUPMENU *topmenu = (POPUPMENU *) USER_HEAP_LIN_ADDR( pmt->hTopMenu );
@@ -1987,11 +1987,11 @@
*
* Return TRUE if we can go on with menu tracking.
*/
-static BOOL32 MENU_ButtonDown( MTRACKER* pmt, HMENU32 hPtMenu )
+static BOOL MENU_ButtonDown( MTRACKER* pmt, HMENU hPtMenu )
{
if (hPtMenu)
{
- UINT32 id = 0;
+ UINT id = 0;
POPUPMENU *ptmenu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hPtMenu );
MENUITEM *item;
@@ -2041,11 +2041,11 @@
* 0 otherwise.
* A zero return value indicates that we can't go on with menu tracking.
*/
-static INT32 MENU_ButtonUp( MTRACKER* pmt, HMENU32 hPtMenu )
+static INT MENU_ButtonUp( MTRACKER* pmt, HMENU hPtMenu )
{
if (hPtMenu)
{
- UINT32 id = 0;
+ UINT id = 0;
POPUPMENU *ptmenu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hPtMenu );
MENUITEM *item;
@@ -2078,9 +2078,9 @@
*
* Return TRUE if we can go on with menu tracking.
*/
-static BOOL32 MENU_MouseMove( MTRACKER* pmt, HMENU32 hPtMenu )
+static BOOL MENU_MouseMove( MTRACKER* pmt, HMENU hPtMenu )
{
- UINT32 id = NO_SELECTED_ITEM;
+ UINT id = NO_SELECTED_ITEM;
POPUPMENU *ptmenu = NULL;
if( hPtMenu )
@@ -2111,7 +2111,7 @@
*
* NOTE: WM_NEXTMENU documented in Win32 is a bit different.
*/
-static LRESULT MENU_DoNextMenu( MTRACKER* pmt, UINT32 vk )
+static LRESULT MENU_DoNextMenu( MTRACKER* pmt, UINT vk )
{
POPUPMENU *menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( pmt->hTopMenu );
@@ -2119,9 +2119,9 @@
(vk == VK_RIGHT && menu->FocusedItem == menu->nItems - 1))
{
WND* wndPtr;
- HMENU32 hNewMenu;
- HWND32 hNewWnd;
- UINT32 id = 0;
+ HMENU hNewMenu;
+ HWND hNewWnd;
+ UINT id = 0;
LRESULT l = SendMessage16( pmt->hOwnerWnd, WM_NEXTMENU, (WPARAM16)vk,
(IS_SYSTEM_MENU(menu)) ? GetSubMenu16(pmt->hTopMenu,0) : pmt->hTopMenu );
@@ -2158,7 +2158,7 @@
{
hNewMenu = LOWORD(l); hNewWnd = HIWORD(l);
- if( IsMenu32(hNewMenu) && IsWindow32(hNewWnd) )
+ if( IsMenu(hNewMenu) && IsWindow(hNewWnd) )
{
wndPtr = WIN_FindWndPtr(hNewWnd);
@@ -2208,7 +2208,7 @@
* The idea is not to show the popup if the next input message is
* going to hide it anyway.
*/
-static BOOL32 MENU_SuspendPopup( MTRACKER* pmt, UINT16 uMsg )
+static BOOL MENU_SuspendPopup( MTRACKER* pmt, UINT16 uMsg )
{
MSG16 msg;
@@ -2248,8 +2248,8 @@
static void MENU_KeyLeft( MTRACKER* pmt )
{
POPUPMENU *menu;
- HMENU32 hmenutmp, hmenuprev;
- UINT32 prevcol;
+ HMENU hmenutmp, hmenuprev;
+ UINT prevcol;
hmenuprev = hmenutmp = pmt->hTopMenu;
menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hmenutmp );
@@ -2300,9 +2300,9 @@
*/
static void MENU_KeyRight( MTRACKER* pmt )
{
- HMENU32 hmenutmp;
+ HMENU hmenutmp;
POPUPMENU *menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( pmt->hTopMenu );
- UINT32 nextcol;
+ UINT nextcol;
TRACE(menu, "MENU_KeyRight called, cur %x (%s), top %x (%s).\n",
pmt->hCurrentMenu,
@@ -2354,13 +2354,13 @@
*
* Menu tracking code.
*/
-static INT32 MENU_TrackMenu( HMENU32 hmenu, UINT32 wFlags, INT32 x, INT32 y,
- HWND32 hwnd, const RECT32 *lprect )
+static INT MENU_TrackMenu( HMENU hmenu, UINT wFlags, INT x, INT y,
+ HWND hwnd, const RECT *lprect )
{
- MSG32 msg;
+ MSG msg;
POPUPMENU *menu;
- BOOL32 fRemove;
- INT32 executedMenuId = 0;
+ BOOL fRemove;
+ INT executedMenuId = 0;
MTRACKER mt = { 0, hmenu, hmenu, hwnd, {x, y} }; /* control struct */
fEndMenu = FALSE;
@@ -2381,7 +2381,7 @@
if (!MSG_InternalGetMessage( &msg, msg.hwnd, mt.hOwnerWnd,
MSGF_MENU, PM_NOREMOVE, TRUE )) break;
- TranslateMessage32( &msg );
+ TranslateMessage( &msg );
mt.pt = msg.pt;
fRemove = FALSE;
@@ -2498,7 +2498,7 @@
case WM_CHAR:
{
- UINT32 pos;
+ UINT pos;
if (msg.wParam == '\r' || msg.wParam == ' ')
{
@@ -2514,8 +2514,8 @@
pos = MENU_FindItemByKey( mt.hOwnerWnd, mt.hCurrentMenu,
LOWORD(msg.wParam), FALSE );
- if (pos == (UINT32)-2) fEndMenu = TRUE;
- else if (pos == (UINT32)-1) MessageBeep32(0);
+ if (pos == (UINT)-2) fEndMenu = TRUE;
+ else if (pos == (UINT)-1) MessageBeep(0);
else
{
MENU_SelectItem( mt.hOwnerWnd, mt.hCurrentMenu, pos, TRUE );
@@ -2528,7 +2528,7 @@
}
else
{
- DispatchMessage32A( &msg );
+ DispatchMessageA( &msg );
}
if (!fEndMenu) fRemove = TRUE;
@@ -2536,19 +2536,19 @@
/* finally remove message from the queue */
if (fRemove && !(mt.trackFlags & TF_SKIPREMOVE) )
- PeekMessage32A( &msg, 0, msg.message, msg.message, PM_REMOVE );
+ PeekMessageA( &msg, 0, msg.message, msg.message, PM_REMOVE );
else mt.trackFlags &= ~TF_SKIPREMOVE;
}
ReleaseCapture();
- if( IsWindow32( mt.hOwnerWnd ) )
+ if( IsWindow( mt.hOwnerWnd ) )
{
MENU_HideSubPopups( mt.hOwnerWnd, mt.hTopMenu, FALSE );
menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( mt.hTopMenu );
if (menu && menu->wFlags & MF_POPUP)
{
- ShowWindow32( menu->hWnd, SW_HIDE );
+ ShowWindow( menu->hWnd, SW_HIDE );
uSubPWndLevel = 0;
}
MENU_SelectItem( mt.hOwnerWnd, mt.hTopMenu, NO_SELECTED_ITEM, FALSE );
@@ -2563,9 +2563,9 @@
/***********************************************************************
* MENU_InitTracking
*/
-static BOOL32 MENU_InitTracking(HWND32 hWnd, HMENU32 hMenu)
+static BOOL MENU_InitTracking(HWND hWnd, HMENU hMenu)
{
- HideCaret32(0);
+ HideCaret(0);
SendMessage16( hWnd, WM_ENTERMENULOOP, 0, 0 );
SendMessage16( hWnd, WM_SETCURSOR, hWnd, HTCAPTION );
SendMessage16( hWnd, WM_INITMENU, hMenu, 0 );
@@ -2577,19 +2577,19 @@
*
* Menu-bar tracking upon a mouse event. Called from NC_HandleSysCommand().
*/
-void MENU_TrackMouseMenuBar( WND* wndPtr, INT32 ht, POINT32 pt )
+void MENU_TrackMouseMenuBar( WND* wndPtr, INT ht, POINT pt )
{
- HWND32 hWnd = wndPtr->hwndSelf;
- HMENU32 hMenu = (ht == HTSYSMENU) ? wndPtr->hSysMenu : wndPtr->wIDmenu;
+ HWND hWnd = wndPtr->hwndSelf;
+ HMENU hMenu = (ht == HTSYSMENU) ? wndPtr->hSysMenu : wndPtr->wIDmenu;
- if (IsMenu32(hMenu))
+ if (IsMenu(hMenu))
{
MENU_InitTracking( hWnd, hMenu );
MENU_TrackMenu( hMenu, TPM_ENTERIDLEEX | TPM_BUTTONDOWN |
TPM_LEFTALIGN | TPM_LEFTBUTTON, pt.x, pt.y, hWnd, NULL );
SendMessage16( hWnd, WM_EXITMENULOOP, 0, 0 );
- ShowCaret32(0);
+ ShowCaret(0);
}
}
@@ -2599,10 +2599,10 @@
*
* Menu-bar tracking upon a keyboard event. Called from NC_HandleSysCommand().
*/
-void MENU_TrackKbdMenuBar( WND* wndPtr, UINT32 wParam, INT32 vkey)
+void MENU_TrackKbdMenuBar( WND* wndPtr, UINT wParam, INT vkey)
{
- UINT32 uItem = NO_SELECTED_ITEM;
- HMENU32 hTrackMenu;
+ UINT uItem = NO_SELECTED_ITEM;
+ HMENU hTrackMenu;
/* find window that has a menu */
@@ -2622,7 +2622,7 @@
else
hTrackMenu = wndPtr->wIDmenu;
- if (IsMenu32( hTrackMenu ))
+ if (IsMenu( hTrackMenu ))
{
MENU_InitTracking( wndPtr->hwndSelf, hTrackMenu );
@@ -2630,9 +2630,9 @@
{
uItem = MENU_FindItemByKey( wndPtr->hwndSelf, hTrackMenu,
vkey, (wParam & HTSYSMENU) );
- if( uItem >= (UINT32)(-2) )
+ if( uItem >= (UINT)(-2) )
{
- if( uItem == (UINT32)(-1) ) MessageBeep32(0);
+ if( uItem == (UINT)(-1) ) MessageBeep(0);
hTrackMenu = 0;
}
}
@@ -2650,7 +2650,7 @@
0, 0, wndPtr->hwndSelf, NULL );
}
SendMessage16( wndPtr->hwndSelf, WM_EXITMENULOOP, 0, 0 );
- ShowCaret32(0);
+ ShowCaret(0);
}
}
@@ -2661,10 +2661,10 @@
BOOL16 WINAPI TrackPopupMenu16( HMENU16 hMenu, UINT16 wFlags, INT16 x, INT16 y,
INT16 nReserved, HWND16 hWnd, const RECT16 *lpRect )
{
- RECT32 r;
+ RECT r;
if (lpRect)
CONV_RECT16TO32( lpRect, &r );
- return TrackPopupMenu32( hMenu, wFlags, x, y, nReserved, hWnd,
+ return TrackPopupMenu( hMenu, wFlags, x, y, nReserved, hWnd,
lpRect ? &r : NULL );
}
@@ -2672,27 +2672,27 @@
/**********************************************************************
* TrackPopupMenu32 (USER32.549)
*/
-BOOL32 WINAPI TrackPopupMenu32( HMENU32 hMenu, UINT32 wFlags, INT32 x, INT32 y,
- INT32 nReserved, HWND32 hWnd, const RECT32 *lpRect )
+BOOL WINAPI TrackPopupMenu( HMENU hMenu, UINT wFlags, INT x, INT y,
+ INT nReserved, HWND hWnd, const RECT *lpRect )
{
- BOOL32 ret = FALSE;
+ BOOL ret = FALSE;
- HideCaret32(0);
+ HideCaret(0);
SendMessage16( hWnd, WM_INITMENUPOPUP, (WPARAM16)hMenu, 0);
if (MENU_ShowPopup( hWnd, hMenu, 0, x, y, 0, 0 ))
ret = MENU_TrackMenu( hMenu, wFlags | TPM_POPUPMENU, 0, 0, hWnd, lpRect );
- ShowCaret32(0);
+ ShowCaret(0);
return ret;
}
/**********************************************************************
* TrackPopupMenuEx (USER32.550)
*/
-BOOL32 WINAPI TrackPopupMenuEx( HMENU32 hMenu, UINT32 wFlags, INT32 x, INT32 y,
- HWND32 hWnd, LPTPMPARAMS lpTpm )
+BOOL WINAPI TrackPopupMenuEx( HMENU hMenu, UINT wFlags, INT x, INT y,
+ HWND hWnd, LPTPMPARAMS lpTpm )
{
FIXME(menu, "not fully implemented\n" );
- return TrackPopupMenu32( hMenu, wFlags, x, y, 0, hWnd,
+ return TrackPopupMenu( hMenu, wFlags, x, y, 0, hWnd,
lpTpm ? &lpTpm->rcExclude : NULL );
}
@@ -2701,7 +2701,7 @@
*
* NOTE: Windows has totally different (and undocumented) popup wndproc.
*/
-LRESULT WINAPI PopupMenuWndProc( HWND32 hwnd, UINT32 message, WPARAM32 wParam,
+LRESULT WINAPI PopupMenuWndProc( HWND hwnd, UINT message, WPARAM wParam,
LPARAM lParam )
{
WND* wndPtr = WIN_FindWndPtr(hwnd);
@@ -2710,8 +2710,8 @@
{
case WM_CREATE:
{
- CREATESTRUCT32A *cs = (CREATESTRUCT32A*)lParam;
- SetWindowLong32A( hwnd, 0, (LONG)cs->lpCreateParams );
+ CREATESTRUCTA *cs = (CREATESTRUCTA*)lParam;
+ SetWindowLongA( hwnd, 0, (LONG)cs->lpCreateParams );
return 0;
}
@@ -2720,11 +2720,11 @@
case WM_PAINT:
{
- PAINTSTRUCT32 ps;
- BeginPaint32( hwnd, &ps );
+ PAINTSTRUCT ps;
+ BeginPaint( hwnd, &ps );
MENU_DrawPopupMenu( hwnd, ps.hdc,
- (HMENU32)GetWindowLong32A( hwnd, 0 ) );
- EndPaint32( hwnd, &ps );
+ (HMENU)GetWindowLongA( hwnd, 0 ) );
+ EndPaint( hwnd, &ps );
return 0;
}
case WM_ERASEBKGND:
@@ -2753,24 +2753,24 @@
if( wParam )
{
- if( !(*(HMENU32*)wndPtr->wExtra) )
+ if( !(*(HMENU*)wndPtr->wExtra) )
ERR(menu,"no menu to display\n");
}
else
- *(HMENU32*)wndPtr->wExtra = 0;
+ *(HMENU*)wndPtr->wExtra = 0;
break;
case MM_SETMENUHANDLE:
- *(HMENU32*)wndPtr->wExtra = (HMENU32)wParam;
+ *(HMENU*)wndPtr->wExtra = (HMENU)wParam;
break;
case MM_GETMENUHANDLE:
- return *(HMENU32*)wndPtr->wExtra;
+ return *(HMENU*)wndPtr->wExtra;
default:
- return DefWindowProc32A( hwnd, message, wParam, lParam );
+ return DefWindowProcA( hwnd, message, wParam, lParam );
}
return 0;
}
@@ -2781,11 +2781,11 @@
*
* Compute the size of the menu bar height. Used by NC_HandleNCCalcSize().
*/
-UINT32 MENU_GetMenuBarHeight( HWND32 hwnd, UINT32 menubarWidth,
- INT32 orgX, INT32 orgY )
+UINT MENU_GetMenuBarHeight( HWND hwnd, UINT menubarWidth,
+ INT orgX, INT orgY )
{
- HDC32 hdc;
- RECT32 rectBar;
+ HDC hdc;
+ RECT rectBar;
WND *wndPtr;
LPPOPUPMENU lppop;
@@ -2795,10 +2795,10 @@
if (!(wndPtr = WIN_FindWndPtr( hwnd ))) return 0;
if (!(lppop = (LPPOPUPMENU)USER_HEAP_LIN_ADDR((HMENU16)wndPtr->wIDmenu)))
return 0;
- hdc = GetDCEx32( hwnd, 0, DCX_CACHE | DCX_WINDOW );
- SetRect32(&rectBar, orgX, orgY, orgX+menubarWidth, orgY+SYSMETRICS_CYMENU);
+ hdc = GetDCEx( hwnd, 0, DCX_CACHE | DCX_WINDOW );
+ SetRect(&rectBar, orgX, orgY, orgX+menubarWidth, orgY+SYSMETRICS_CYMENU);
MENU_MenuBarCalcSize( hdc, &rectBar, lppop, hwnd );
- ReleaseDC32( hwnd, hdc );
+ ReleaseDC( hwnd, hdc );
return lppop->Height;
}
@@ -2832,42 +2832,42 @@
/*******************************************************************
* ChangeMenu32A (USER32.23)
*/
-BOOL32 WINAPI ChangeMenu32A( HMENU32 hMenu, UINT32 pos, LPCSTR data,
- UINT32 id, UINT32 flags )
+BOOL WINAPI ChangeMenuA( HMENU hMenu, UINT pos, LPCSTR data,
+ UINT id, UINT flags )
{
TRACE(menu,"menu=%08x pos=%d data=%08lx id=%08x flags=%08x\n",
hMenu, pos, (DWORD)data, id, flags );
- if (flags & MF_APPEND) return AppendMenu32A( hMenu, flags & ~MF_APPEND,
+ if (flags & MF_APPEND) return AppendMenuA( hMenu, flags & ~MF_APPEND,
id, data );
- if (flags & MF_DELETE) return DeleteMenu32(hMenu, pos, flags & ~MF_DELETE);
- if (flags & MF_CHANGE) return ModifyMenu32A(hMenu, pos, flags & ~MF_CHANGE,
+ if (flags & MF_DELETE) return DeleteMenu(hMenu, pos, flags & ~MF_DELETE);
+ if (flags & MF_CHANGE) return ModifyMenuA(hMenu, pos, flags & ~MF_CHANGE,
id, data );
- if (flags & MF_REMOVE) return RemoveMenu32( hMenu,
+ if (flags & MF_REMOVE) return RemoveMenu( hMenu,
flags & MF_BYPOSITION ? pos : id,
flags & ~MF_REMOVE );
/* Default: MF_INSERT */
- return InsertMenu32A( hMenu, pos, flags, id, data );
+ return InsertMenuA( hMenu, pos, flags, id, data );
}
/*******************************************************************
* ChangeMenu32W (USER32.24)
*/
-BOOL32 WINAPI ChangeMenu32W( HMENU32 hMenu, UINT32 pos, LPCWSTR data,
- UINT32 id, UINT32 flags )
+BOOL WINAPI ChangeMenuW( HMENU hMenu, UINT pos, LPCWSTR data,
+ UINT id, UINT flags )
{
TRACE(menu,"menu=%08x pos=%d data=%08lx id=%08x flags=%08x\n",
hMenu, pos, (DWORD)data, id, flags );
- if (flags & MF_APPEND) return AppendMenu32W( hMenu, flags & ~MF_APPEND,
+ if (flags & MF_APPEND) return AppendMenuW( hMenu, flags & ~MF_APPEND,
id, data );
- if (flags & MF_DELETE) return DeleteMenu32(hMenu, pos, flags & ~MF_DELETE);
- if (flags & MF_CHANGE) return ModifyMenu32W(hMenu, pos, flags & ~MF_CHANGE,
+ if (flags & MF_DELETE) return DeleteMenu(hMenu, pos, flags & ~MF_DELETE);
+ if (flags & MF_CHANGE) return ModifyMenuW(hMenu, pos, flags & ~MF_CHANGE,
id, data );
- if (flags & MF_REMOVE) return RemoveMenu32( hMenu,
+ if (flags & MF_REMOVE) return RemoveMenu( hMenu,
flags & MF_BYPOSITION ? pos : id,
flags & ~MF_REMOVE );
/* Default: MF_INSERT */
- return InsertMenu32W( hMenu, pos, flags, id, data );
+ return InsertMenuW( hMenu, pos, flags, id, data );
}
@@ -2876,14 +2876,14 @@
*/
BOOL16 WINAPI CheckMenuItem16( HMENU16 hMenu, UINT16 id, UINT16 flags )
{
- return (BOOL16)CheckMenuItem32( hMenu, id, flags );
+ return (BOOL16)CheckMenuItem( hMenu, id, flags );
}
/*******************************************************************
* CheckMenuItem32 (USER32.46)
*/
-DWORD WINAPI CheckMenuItem32( HMENU32 hMenu, UINT32 id, UINT32 flags )
+DWORD WINAPI CheckMenuItem( HMENU hMenu, UINT id, UINT flags )
{
MENUITEM *item;
DWORD ret;
@@ -2902,23 +2902,23 @@
*/
UINT16 WINAPI EnableMenuItem16( HMENU16 hMenu, UINT16 wItemID, UINT16 wFlags )
{
- return EnableMenuItem32( hMenu, wItemID, wFlags );
+ return EnableMenuItem( hMenu, wItemID, wFlags );
}
/**********************************************************************
* EnableMenuItem32 (USER32.170)
*/
-UINT32 WINAPI EnableMenuItem32( HMENU32 hMenu, UINT32 wItemID, UINT32 wFlags )
+UINT WINAPI EnableMenuItem( HMENU hMenu, UINT wItemID, UINT wFlags )
{
- UINT32 oldflags;
+ UINT oldflags;
MENUITEM *item;
TRACE(menu,"(%04x, %04X, %04X) !\n",
hMenu, wItemID, wFlags);
if (!(item = MENU_FindItem( &hMenu, &wItemID, wFlags )))
- return (UINT32)-1;
+ return (UINT)-1;
oldflags = item->fState & (MF_GRAYED | MF_DISABLED);
item->fState ^= (oldflags ^ wFlags) & (MF_GRAYED | MF_DISABLED);
@@ -2932,15 +2932,15 @@
INT16 WINAPI GetMenuString16( HMENU16 hMenu, UINT16 wItemID,
LPSTR str, INT16 nMaxSiz, UINT16 wFlags )
{
- return GetMenuString32A( hMenu, wItemID, str, nMaxSiz, wFlags );
+ return GetMenuStringA( hMenu, wItemID, str, nMaxSiz, wFlags );
}
/*******************************************************************
* GetMenuString32A (USER32.268)
*/
-INT32 WINAPI GetMenuString32A( HMENU32 hMenu, UINT32 wItemID,
- LPSTR str, INT32 nMaxSiz, UINT32 wFlags )
+INT WINAPI GetMenuStringA( HMENU hMenu, UINT wItemID,
+ LPSTR str, INT nMaxSiz, UINT wFlags )
{
MENUITEM *item;
@@ -2950,7 +2950,7 @@
str[0] = '\0';
if (!(item = MENU_FindItem( &hMenu, &wItemID, wFlags ))) return 0;
if (!IS_STRING_ITEM(item->fType)) return 0;
- lstrcpyn32A( str, item->text, nMaxSiz );
+ lstrcpynA( str, item->text, nMaxSiz );
TRACE(menu, "returning '%s'\n", str );
return strlen(str);
}
@@ -2959,8 +2959,8 @@
/*******************************************************************
* GetMenuString32W (USER32.269)
*/
-INT32 WINAPI GetMenuString32W( HMENU32 hMenu, UINT32 wItemID,
- LPWSTR str, INT32 nMaxSiz, UINT32 wFlags )
+INT WINAPI GetMenuStringW( HMENU hMenu, UINT wItemID,
+ LPWSTR str, INT nMaxSiz, UINT wFlags )
{
MENUITEM *item;
@@ -2971,7 +2971,7 @@
if (!(item = MENU_FindItem( &hMenu, &wItemID, wFlags ))) return 0;
if (!IS_STRING_ITEM(item->fType)) return 0;
lstrcpynAtoW( str, item->text, nMaxSiz );
- return lstrlen32W(str);
+ return lstrlenW(str);
}
@@ -2981,15 +2981,15 @@
BOOL16 WINAPI HiliteMenuItem16( HWND16 hWnd, HMENU16 hMenu, UINT16 wItemID,
UINT16 wHilite )
{
- return HiliteMenuItem32( hWnd, hMenu, wItemID, wHilite );
+ return HiliteMenuItem( hWnd, hMenu, wItemID, wHilite );
}
/**********************************************************************
* HiliteMenuItem32 (USER32.318)
*/
-BOOL32 WINAPI HiliteMenuItem32( HWND32 hWnd, HMENU32 hMenu, UINT32 wItemID,
- UINT32 wHilite )
+BOOL WINAPI HiliteMenuItem( HWND hWnd, HMENU hMenu, UINT wItemID,
+ UINT wHilite )
{
LPPOPUPMENU menu;
TRACE(menu,"(%04x, %04x, %04x, %04x);\n",
@@ -3008,14 +3008,14 @@
*/
UINT16 WINAPI GetMenuState16( HMENU16 hMenu, UINT16 wItemID, UINT16 wFlags )
{
- return GetMenuState32( hMenu, wItemID, wFlags );
+ return GetMenuState( hMenu, wItemID, wFlags );
}
/**********************************************************************
* GetMenuState32 (USER32.267)
*/
-UINT32 WINAPI GetMenuState32( HMENU32 hMenu, UINT32 wItemID, UINT32 wFlags )
+UINT WINAPI GetMenuState( HMENU hMenu, UINT wItemID, UINT wFlags )
{
MENUITEM *item;
TRACE(menu,"(%04x, %04x, %04x);\n",
@@ -3054,7 +3054,7 @@
/**********************************************************************
* GetMenuItemCount32 (USER32.262)
*/
-INT32 WINAPI GetMenuItemCount32( HMENU32 hMenu )
+INT WINAPI GetMenuItemCount( HMENU hMenu )
{
LPPOPUPMENU menu = (LPPOPUPMENU) USER_HEAP_LIN_ADDR(hMenu);
if (!IS_A_MENU(menu)) return -1;
@@ -3081,7 +3081,7 @@
/**********************************************************************
* GetMenuItemID32 (USER32.263)
*/
-UINT32 WINAPI GetMenuItemID32( HMENU32 hMenu, INT32 nPos )
+UINT WINAPI GetMenuItemID( HMENU hMenu, INT nPos )
{
LPPOPUPMENU menu;
@@ -3098,20 +3098,20 @@
BOOL16 WINAPI InsertMenu16( HMENU16 hMenu, UINT16 pos, UINT16 flags,
UINT16 id, SEGPTR data )
{
- UINT32 pos32 = (UINT32)pos;
- if ((pos == (UINT16)-1) && (flags & MF_BYPOSITION)) pos32 = (UINT32)-1;
+ UINT pos32 = (UINT)pos;
+ if ((pos == (UINT16)-1) && (flags & MF_BYPOSITION)) pos32 = (UINT)-1;
if (IS_STRING_ITEM(flags) && data)
- return InsertMenu32A( hMenu, pos32, flags, id,
+ return InsertMenuA( hMenu, pos32, flags, id,
(LPSTR)PTR_SEG_TO_LIN(data) );
- return InsertMenu32A( hMenu, pos32, flags, id, (LPSTR)data );
+ return InsertMenuA( hMenu, pos32, flags, id, (LPSTR)data );
}
/*******************************************************************
* InsertMenu32A (USER32.322)
*/
-BOOL32 WINAPI InsertMenu32A( HMENU32 hMenu, UINT32 pos, UINT32 flags,
- UINT32 id, LPCSTR str )
+BOOL WINAPI InsertMenuA( HMENU hMenu, UINT pos, UINT flags,
+ UINT id, LPCSTR str )
{
MENUITEM *item;
@@ -3127,7 +3127,7 @@
if (!(MENU_SetItemData( item, flags, id, str )))
{
- RemoveMenu32( hMenu, pos, flags );
+ RemoveMenu( hMenu, pos, flags );
return FALSE;
}
@@ -3142,19 +3142,19 @@
/*******************************************************************
* InsertMenu32W (USER32.325)
*/
-BOOL32 WINAPI InsertMenu32W( HMENU32 hMenu, UINT32 pos, UINT32 flags,
- UINT32 id, LPCWSTR str )
+BOOL WINAPI InsertMenuW( HMENU hMenu, UINT pos, UINT flags,
+ UINT id, LPCWSTR str )
{
- BOOL32 ret;
+ BOOL ret;
if (IS_STRING_ITEM(flags) && str)
{
LPSTR newstr = HEAP_strdupWtoA( GetProcessHeap(), 0, str );
- ret = InsertMenu32A( hMenu, pos, flags, id, newstr );
+ ret = InsertMenuA( hMenu, pos, flags, id, newstr );
HeapFree( GetProcessHeap(), 0, newstr );
return ret;
}
- else return InsertMenu32A( hMenu, pos, flags, id, (LPCSTR)str );
+ else return InsertMenuA( hMenu, pos, flags, id, (LPCSTR)str );
}
@@ -3170,20 +3170,20 @@
/*******************************************************************
* AppendMenu32A (USER32.5)
*/
-BOOL32 WINAPI AppendMenu32A( HMENU32 hMenu, UINT32 flags,
- UINT32 id, LPCSTR data )
+BOOL WINAPI AppendMenuA( HMENU hMenu, UINT flags,
+ UINT id, LPCSTR data )
{
- return InsertMenu32A( hMenu, -1, flags | MF_BYPOSITION, id, data );
+ return InsertMenuA( hMenu, -1, flags | MF_BYPOSITION, id, data );
}
/*******************************************************************
* AppendMenu32W (USER32.6)
*/
-BOOL32 WINAPI AppendMenu32W( HMENU32 hMenu, UINT32 flags,
- UINT32 id, LPCWSTR data )
+BOOL WINAPI AppendMenuW( HMENU hMenu, UINT flags,
+ UINT id, LPCWSTR data )
{
- return InsertMenu32W( hMenu, -1, flags | MF_BYPOSITION, id, data );
+ return InsertMenuW( hMenu, -1, flags | MF_BYPOSITION, id, data );
}
@@ -3192,14 +3192,14 @@
*/
BOOL16 WINAPI RemoveMenu16( HMENU16 hMenu, UINT16 nPos, UINT16 wFlags )
{
- return RemoveMenu32( hMenu, nPos, wFlags );
+ return RemoveMenu( hMenu, nPos, wFlags );
}
/**********************************************************************
* RemoveMenu32 (USER32.441)
*/
-BOOL32 WINAPI RemoveMenu32( HMENU32 hMenu, UINT32 nPos, UINT32 wFlags )
+BOOL WINAPI RemoveMenu( HMENU hMenu, UINT nPos, UINT wFlags )
{
LPPOPUPMENU menu;
MENUITEM *item;
@@ -3237,20 +3237,20 @@
*/
BOOL16 WINAPI DeleteMenu16( HMENU16 hMenu, UINT16 nPos, UINT16 wFlags )
{
- return DeleteMenu32( hMenu, nPos, wFlags );
+ return DeleteMenu( hMenu, nPos, wFlags );
}
/**********************************************************************
* DeleteMenu32 (USER32.129)
*/
-BOOL32 WINAPI DeleteMenu32( HMENU32 hMenu, UINT32 nPos, UINT32 wFlags )
+BOOL WINAPI DeleteMenu( HMENU hMenu, UINT nPos, UINT wFlags )
{
MENUITEM *item = MENU_FindItem( &hMenu, &nPos, wFlags );
if (!item) return FALSE;
- if (item->fType & MF_POPUP) DestroyMenu32( item->hSubMenu );
+ if (item->fType & MF_POPUP) DestroyMenu( item->hSubMenu );
/* nPos is now the position of the item */
- RemoveMenu32( hMenu, nPos, wFlags | MF_BYPOSITION );
+ RemoveMenu( hMenu, nPos, wFlags | MF_BYPOSITION );
return TRUE;
}
@@ -3262,17 +3262,17 @@
UINT16 id, SEGPTR data )
{
if (IS_STRING_ITEM(flags))
- return ModifyMenu32A( hMenu, pos, flags, id,
+ return ModifyMenuA( hMenu, pos, flags, id,
(LPSTR)PTR_SEG_TO_LIN(data) );
- return ModifyMenu32A( hMenu, pos, flags, id, (LPSTR)data );
+ return ModifyMenuA( hMenu, pos, flags, id, (LPSTR)data );
}
/*******************************************************************
* ModifyMenu32A (USER32.397)
*/
-BOOL32 WINAPI ModifyMenu32A( HMENU32 hMenu, UINT32 pos, UINT32 flags,
- UINT32 id, LPCSTR str )
+BOOL WINAPI ModifyMenuA( HMENU hMenu, UINT pos, UINT flags,
+ UINT id, LPCSTR str )
{
MENUITEM *item;
@@ -3296,19 +3296,19 @@
/*******************************************************************
* ModifyMenu32W (USER32.398)
*/
-BOOL32 WINAPI ModifyMenu32W( HMENU32 hMenu, UINT32 pos, UINT32 flags,
- UINT32 id, LPCWSTR str )
+BOOL WINAPI ModifyMenuW( HMENU hMenu, UINT pos, UINT flags,
+ UINT id, LPCWSTR str )
{
- BOOL32 ret;
+ BOOL ret;
if (IS_STRING_ITEM(flags) && str)
{
LPSTR newstr = HEAP_strdupWtoA( GetProcessHeap(), 0, str );
- ret = ModifyMenu32A( hMenu, pos, flags, id, newstr );
+ ret = ModifyMenuA( hMenu, pos, flags, id, newstr );
HeapFree( GetProcessHeap(), 0, newstr );
return ret;
}
- else return ModifyMenu32A( hMenu, pos, flags, id, (LPCSTR)str );
+ else return ModifyMenuA( hMenu, pos, flags, id, (LPCSTR)str );
}
@@ -3317,19 +3317,19 @@
*/
HMENU16 WINAPI CreatePopupMenu16(void)
{
- return CreatePopupMenu32();
+ return CreatePopupMenu();
}
/**********************************************************************
* CreatePopupMenu32 (USER32.82)
*/
-HMENU32 WINAPI CreatePopupMenu32(void)
+HMENU WINAPI CreatePopupMenu(void)
{
- HMENU32 hmenu;
+ HMENU hmenu;
POPUPMENU *menu;
- if (!(hmenu = CreateMenu32())) return 0;
+ if (!(hmenu = CreateMenu())) return 0;
menu = (POPUPMENU *) USER_HEAP_LIN_ADDR( hmenu );
menu->wFlags |= MF_POPUP;
return hmenu;
@@ -3351,15 +3351,15 @@
BOOL16 WINAPI SetMenuItemBitmaps16( HMENU16 hMenu, UINT16 nPos, UINT16 wFlags,
HBITMAP16 hNewUnCheck, HBITMAP16 hNewCheck)
{
- return SetMenuItemBitmaps32( hMenu, nPos, wFlags, hNewUnCheck, hNewCheck );
+ return SetMenuItemBitmaps( hMenu, nPos, wFlags, hNewUnCheck, hNewCheck );
}
/**********************************************************************
* SetMenuItemBitmaps32 (USER32.490)
*/
-BOOL32 WINAPI SetMenuItemBitmaps32( HMENU32 hMenu, UINT32 nPos, UINT32 wFlags,
- HBITMAP32 hNewUnCheck, HBITMAP32 hNewCheck)
+BOOL WINAPI SetMenuItemBitmaps( HMENU hMenu, UINT nPos, UINT wFlags,
+ HBITMAP hNewUnCheck, HBITMAP hNewCheck)
{
MENUITEM *item;
TRACE(menu,"(%04x, %04x, %04x, %04x, %04x)\n",
@@ -3385,16 +3385,16 @@
*/
HMENU16 WINAPI CreateMenu16(void)
{
- return CreateMenu32();
+ return CreateMenu();
}
/**********************************************************************
* CreateMenu32 (USER32.81)
*/
-HMENU32 WINAPI CreateMenu32(void)
+HMENU WINAPI CreateMenu(void)
{
- HMENU32 hMenu;
+ HMENU hMenu;
LPPOPUPMENU menu;
if (!(hMenu = USER_HEAP_ALLOC( sizeof(POPUPMENU) ))) return 0;
menu = (LPPOPUPMENU) USER_HEAP_LIN_ADDR(hMenu);
@@ -3417,14 +3417,14 @@
*/
BOOL16 WINAPI DestroyMenu16( HMENU16 hMenu )
{
- return DestroyMenu32( hMenu );
+ return DestroyMenu( hMenu );
}
/**********************************************************************
* DestroyMenu32 (USER32.134)
*/
-BOOL32 WINAPI DestroyMenu32( HMENU32 hMenu )
+BOOL WINAPI DestroyMenu( HMENU hMenu )
{
TRACE(menu,"(%04x)\n", hMenu);
@@ -3434,8 +3434,8 @@
{
LPPOPUPMENU lppop = (LPPOPUPMENU) USER_HEAP_LIN_ADDR(hMenu);
- if( pTopPopupWnd && (hMenu == *(HMENU32*)pTopPopupWnd->wExtra) )
- *(UINT32*)pTopPopupWnd->wExtra = 0;
+ if( pTopPopupWnd && (hMenu == *(HMENU*)pTopPopupWnd->wExtra) )
+ *(UINT*)pTopPopupWnd->wExtra = 0;
if (IS_A_MENU( lppop ))
{
@@ -3443,7 +3443,7 @@
if ((lppop->wFlags & MF_POPUP) && lppop->hWnd &&
(!pTopPopupWnd || (lppop->hWnd != pTopPopupWnd->hwndSelf)))
- DestroyWindow32( lppop->hWnd );
+ DestroyWindow( lppop->hWnd );
if (lppop->items) /* recursively destroy submenus */
{
@@ -3451,7 +3451,7 @@
MENUITEM *item = lppop->items;
for (i = lppop->nItems; i > 0; i--, item++)
{
- if (item->fType & MF_POPUP) DestroyMenu32(item->hSubMenu);
+ if (item->fType & MF_POPUP) DestroyMenu(item->hSubMenu);
MENU_FreeItemData( item );
}
HeapFree( SystemHeap, 0, lppop->items );
@@ -3469,14 +3469,14 @@
*/
HMENU16 WINAPI GetSystemMenu16( HWND16 hWnd, BOOL16 bRevert )
{
- return GetSystemMenu32( hWnd, bRevert );
+ return GetSystemMenu( hWnd, bRevert );
}
/**********************************************************************
* GetSystemMenu32 (USER32.291)
*/
-HMENU32 WINAPI GetSystemMenu32( HWND32 hWnd, BOOL32 bRevert )
+HMENU WINAPI GetSystemMenu( HWND hWnd, BOOL bRevert )
{
WND *wndPtr = WIN_FindWndPtr( hWnd );
@@ -3486,7 +3486,7 @@
{
if( bRevert )
{
- DestroyMenu32(wndPtr->hSysMenu);
+ DestroyMenu(wndPtr->hSysMenu);
wndPtr->hSysMenu = 0;
}
else
@@ -3499,7 +3499,7 @@
}
if(!wndPtr->hSysMenu && (wndPtr->dwStyle & WS_SYSMENU) )
- wndPtr->hSysMenu = MENU_GetSysMenu( hWnd, (HMENU32)(-1) );
+ wndPtr->hSysMenu = MENU_GetSysMenu( hWnd, (HMENU)(-1) );
if( wndPtr->hSysMenu )
return GetSubMenu16(wndPtr->hSysMenu, 0);
@@ -3513,20 +3513,20 @@
*/
BOOL16 WINAPI SetSystemMenu16( HWND16 hwnd, HMENU16 hMenu )
{
- return SetSystemMenu32( hwnd, hMenu );
+ return SetSystemMenu( hwnd, hMenu );
}
/*******************************************************************
* SetSystemMenu32 (USER32.508)
*/
-BOOL32 WINAPI SetSystemMenu32( HWND32 hwnd, HMENU32 hMenu )
+BOOL WINAPI SetSystemMenu( HWND hwnd, HMENU hMenu )
{
WND *wndPtr = WIN_FindWndPtr(hwnd);
if (wndPtr)
{
- if (wndPtr->hSysMenu) DestroyMenu32( wndPtr->hSysMenu );
+ if (wndPtr->hSysMenu) DestroyMenu( wndPtr->hSysMenu );
wndPtr->hSysMenu = MENU_GetSysMenu( hwnd, hMenu );
return TRUE;
}
@@ -3549,11 +3549,11 @@
/**********************************************************************
* GetMenu32 (USER32.257)
*/
-HMENU32 WINAPI GetMenu32( HWND32 hWnd )
+HMENU WINAPI GetMenu( HWND hWnd )
{
WND * wndPtr = WIN_FindWndPtr(hWnd);
if (wndPtr && !(wndPtr->dwStyle & WS_CHILD))
- return (HMENU32)wndPtr->wIDmenu;
+ return (HMENU)wndPtr->wIDmenu;
return 0;
}
@@ -3563,14 +3563,14 @@
*/
BOOL16 WINAPI SetMenu16( HWND16 hWnd, HMENU16 hMenu )
{
- return SetMenu32( hWnd, hMenu );
+ return SetMenu( hWnd, hMenu );
}
/**********************************************************************
* SetMenu32 (USER32.487)
*/
-BOOL32 WINAPI SetMenu32( HWND32 hWnd, HMENU32 hMenu )
+BOOL WINAPI SetMenu( HWND hWnd, HMENU hMenu )
{
WND * wndPtr = WIN_FindWndPtr(hWnd);
@@ -3578,9 +3578,9 @@
if (wndPtr && !(wndPtr->dwStyle & WS_CHILD))
{
- if (GetCapture32() == hWnd) ReleaseCapture();
+ if (GetCapture() == hWnd) ReleaseCapture();
- wndPtr->wIDmenu = (UINT32)hMenu;
+ wndPtr->wIDmenu = (UINT)hMenu;
if (hMenu != 0)
{
LPPOPUPMENU lpmenu;
@@ -3590,8 +3590,8 @@
lpmenu->wFlags &= ~MF_POPUP; /* Can't be a popup */
lpmenu->Height = 0; /* Make sure we recalculate the size */
}
- if (IsWindowVisible32(hWnd))
- SetWindowPos32( hWnd, 0, 0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE |
+ if (IsWindowVisible(hWnd))
+ SetWindowPos( hWnd, 0, 0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE |
SWP_NOACTIVATE | SWP_NOZORDER | SWP_FRAMECHANGED );
return TRUE;
}
@@ -3605,19 +3605,19 @@
*/
HMENU16 WINAPI GetSubMenu16( HMENU16 hMenu, INT16 nPos )
{
- return GetSubMenu32( hMenu, nPos );
+ return GetSubMenu( hMenu, nPos );
}
/**********************************************************************
* GetSubMenu32 (USER32.288)
*/
-HMENU32 WINAPI GetSubMenu32( HMENU32 hMenu, INT32 nPos )
+HMENU WINAPI GetSubMenu( HMENU hMenu, INT nPos )
{
LPPOPUPMENU lppop;
if (!(lppop = (LPPOPUPMENU) USER_HEAP_LIN_ADDR(hMenu))) return 0;
- if ((UINT32)nPos >= lppop->nItems) return 0;
+ if ((UINT)nPos >= lppop->nItems) return 0;
if (!(lppop->items[nPos].fType & MF_POPUP)) return 0;
return lppop->items[nPos].hSubMenu;
}
@@ -3628,14 +3628,14 @@
*/
void WINAPI DrawMenuBar16( HWND16 hWnd )
{
- DrawMenuBar32( hWnd );
+ DrawMenuBar( hWnd );
}
/**********************************************************************
* DrawMenuBar32 (USER32.161)
*/
-BOOL32 WINAPI DrawMenuBar32( HWND32 hWnd )
+BOOL WINAPI DrawMenuBar( HWND hWnd )
{
LPPOPUPMENU lppop;
WND *wndPtr = WIN_FindWndPtr(hWnd);
@@ -3645,7 +3645,7 @@
if (lppop == NULL) return FALSE;
lppop->Height = 0; /* Make sure we call MENU_MenuBarCalcSize */
- SetWindowPos32( hWnd, 0, 0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE |
+ SetWindowPos( hWnd, 0, 0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE |
SWP_NOACTIVATE | SWP_NOZORDER | SWP_FRAMECHANGED );
return TRUE;
}
@@ -3665,10 +3665,10 @@
/***********************************************************************
* LookupMenuHandle (USER.217)
*/
-HMENU16 WINAPI LookupMenuHandle( HMENU16 hmenu, INT16 id )
+HMENU16 WINAPI LookupMenuHandle16( HMENU16 hmenu, INT16 id )
{
- HMENU32 hmenu32 = hmenu;
- UINT32 id32 = id;
+ HMENU hmenu32 = hmenu;
+ UINT id32 = id;
if (!MENU_FindItem( &hmenu32, &id32, MF_BYCOMMAND )) return 0;
else return hmenu32;
}
@@ -3696,7 +3696,7 @@
/* check for Win32 module */
if (HIWORD(instance))
- return LoadMenu32A(instance,PTR_SEG_TO_LIN(name));
+ return LoadMenuA(instance,PTR_SEG_TO_LIN(name));
instance = GetExePtr( instance );
if (!(hRsrc = FindResource16( instance, name, RT_MENU16 ))) return 0;
@@ -3710,22 +3710,22 @@
/*****************************************************************
* LoadMenu32A (USER32.370)
*/
-HMENU32 WINAPI LoadMenu32A( HINSTANCE32 instance, LPCSTR name )
+HMENU WINAPI LoadMenuA( HINSTANCE instance, LPCSTR name )
{
- HRSRC32 hrsrc = FindResource32A( instance, name, RT_MENU32A );
+ HRSRC hrsrc = FindResourceA( instance, name, RT_MENUA );
if (!hrsrc) return 0;
- return LoadMenuIndirect32A( (LPCVOID)LoadResource32( instance, hrsrc ));
+ return LoadMenuIndirectA( (LPCVOID)LoadResource( instance, hrsrc ));
}
/*****************************************************************
* LoadMenu32W (USER32.373)
*/
-HMENU32 WINAPI LoadMenu32W( HINSTANCE32 instance, LPCWSTR name )
+HMENU WINAPI LoadMenuW( HINSTANCE instance, LPCWSTR name )
{
- HRSRC32 hrsrc = FindResource32W( instance, name, RT_MENU32W );
+ HRSRC hrsrc = FindResourceW( instance, name, RT_MENUW );
if (!hrsrc) return 0;
- return LoadMenuIndirect32W( (LPCVOID)LoadResource32( instance, hrsrc ));
+ return LoadMenuIndirectW( (LPCVOID)LoadResource( instance, hrsrc ));
}
@@ -3748,10 +3748,10 @@
}
offset = GET_WORD(p);
p += sizeof(WORD) + offset;
- if (!(hMenu = CreateMenu32())) return 0;
+ if (!(hMenu = CreateMenu())) return 0;
if (!MENU_ParseResource( p, hMenu, FALSE ))
{
- DestroyMenu32( hMenu );
+ DestroyMenu( hMenu );
return 0;
}
return hMenu;
@@ -3761,7 +3761,7 @@
/**********************************************************************
* LoadMenuIndirect32A (USER32.371)
*/
-HMENU32 WINAPI LoadMenuIndirect32A( LPCVOID template )
+HMENU WINAPI LoadMenuIndirectA( LPCVOID template )
{
HMENU16 hMenu;
WORD version, offset;
@@ -3775,20 +3775,20 @@
case 0:
offset = GET_WORD(p);
p += sizeof(WORD) + offset;
- if (!(hMenu = CreateMenu32())) return 0;
+ if (!(hMenu = CreateMenu())) return 0;
if (!MENU_ParseResource( p, hMenu, TRUE ))
{
- DestroyMenu32( hMenu );
+ DestroyMenu( hMenu );
return 0;
}
return hMenu;
case 1:
offset = GET_WORD(p);
p += sizeof(WORD) + offset;
- if (!(hMenu = CreateMenu32())) return 0;
+ if (!(hMenu = CreateMenu())) return 0;
if (!MENUEX_ParseResource( p, hMenu))
{
- DestroyMenu32( hMenu );
+ DestroyMenu( hMenu );
return 0;
}
return hMenu;
@@ -3802,10 +3802,10 @@
/**********************************************************************
* LoadMenuIndirect32W (USER32.372)
*/
-HMENU32 WINAPI LoadMenuIndirect32W( LPCVOID template )
+HMENU WINAPI LoadMenuIndirectW( LPCVOID template )
{
/* FIXME: is there anything different between A and W? */
- return LoadMenuIndirect32A( template );
+ return LoadMenuIndirectA( template );
}
@@ -3822,7 +3822,7 @@
/**********************************************************************
* IsMenu32 (USER32.346)
*/
-BOOL32 WINAPI IsMenu32(HMENU32 hmenu)
+BOOL WINAPI IsMenu(HMENU hmenu)
{
LPPOPUPMENU menu = (LPPOPUPMENU) USER_HEAP_LIN_ADDR(hmenu);
return IS_A_MENU(menu);
@@ -3832,10 +3832,10 @@
* GetMenuItemInfo32_common
*/
-static BOOL32 GetMenuItemInfo32_common ( HMENU32 hmenu, UINT32 item,
- BOOL32 bypos,
- LPMENUITEMINFO32A lpmii,
- BOOL32 unicode)
+static BOOL GetMenuItemInfo_common ( HMENU hmenu, UINT item,
+ BOOL bypos,
+ LPMENUITEMINFOA lpmii,
+ BOOL unicode)
{
MENUITEM *menu = MENU_FindItem (&hmenu, &item, bypos? MF_BYPOSITION : 0);
debug_print_menuitem("GetMenuItemInfo32_common: ", menu, "");
@@ -3852,7 +3852,7 @@
menu->text,
lpmii->cch);
else
- lstrcpyn32A(lpmii->dwTypeData,
+ lstrcpynA(lpmii->dwTypeData,
menu->text,
lpmii->cch);
}
@@ -3887,29 +3887,29 @@
/**********************************************************************
* GetMenuItemInfo32A (USER32.264)
*/
-BOOL32 WINAPI GetMenuItemInfo32A( HMENU32 hmenu, UINT32 item, BOOL32 bypos,
- LPMENUITEMINFO32A lpmii)
+BOOL WINAPI GetMenuItemInfoA( HMENU hmenu, UINT item, BOOL bypos,
+ LPMENUITEMINFOA lpmii)
{
- return GetMenuItemInfo32_common (hmenu, item, bypos, lpmii, FALSE);
+ return GetMenuItemInfo_common (hmenu, item, bypos, lpmii, FALSE);
}
/**********************************************************************
* GetMenuItemInfo32W (USER32.265)
*/
-BOOL32 WINAPI GetMenuItemInfo32W( HMENU32 hmenu, UINT32 item, BOOL32 bypos,
- LPMENUITEMINFO32W lpmii)
+BOOL WINAPI GetMenuItemInfoW( HMENU hmenu, UINT item, BOOL bypos,
+ LPMENUITEMINFOW lpmii)
{
- return GetMenuItemInfo32_common (hmenu, item, bypos,
- (LPMENUITEMINFO32A)lpmii, TRUE);
+ return GetMenuItemInfo_common (hmenu, item, bypos,
+ (LPMENUITEMINFOA)lpmii, TRUE);
}
/**********************************************************************
* SetMenuItemInfo32_common
*/
-static BOOL32 SetMenuItemInfo32_common(MENUITEM * menu,
- const MENUITEMINFO32A *lpmii,
- BOOL32 unicode)
+static BOOL SetMenuItemInfo_common(MENUITEM * menu,
+ const MENUITEMINFOA *lpmii,
+ BOOL unicode)
{
if (!menu) return FALSE;
@@ -3965,27 +3965,27 @@
/**********************************************************************
* SetMenuItemInfo32A (USER32.491)
*/
-BOOL32 WINAPI SetMenuItemInfo32A(HMENU32 hmenu, UINT32 item, BOOL32 bypos,
- const MENUITEMINFO32A *lpmii)
+BOOL WINAPI SetMenuItemInfoA(HMENU hmenu, UINT item, BOOL bypos,
+ const MENUITEMINFOA *lpmii)
{
- return SetMenuItemInfo32_common(MENU_FindItem(&hmenu, &item, bypos? MF_BYPOSITION : 0),
+ return SetMenuItemInfo_common(MENU_FindItem(&hmenu, &item, bypos? MF_BYPOSITION : 0),
lpmii, FALSE);
}
/**********************************************************************
* SetMenuItemInfo32W (USER32.492)
*/
-BOOL32 WINAPI SetMenuItemInfo32W(HMENU32 hmenu, UINT32 item, BOOL32 bypos,
- const MENUITEMINFO32W *lpmii)
+BOOL WINAPI SetMenuItemInfoW(HMENU hmenu, UINT item, BOOL bypos,
+ const MENUITEMINFOW *lpmii)
{
- return SetMenuItemInfo32_common(MENU_FindItem(&hmenu, &item, bypos? MF_BYPOSITION : 0),
- (const MENUITEMINFO32A*)lpmii, TRUE);
+ return SetMenuItemInfo_common(MENU_FindItem(&hmenu, &item, bypos? MF_BYPOSITION : 0),
+ (const MENUITEMINFOA*)lpmii, TRUE);
}
/**********************************************************************
* SetMenuDefaultItem32 (USER32.489)
*/
-BOOL32 WINAPI SetMenuDefaultItem32(HMENU32 hmenu, UINT32 item, UINT32 bypos)
+BOOL WINAPI SetMenuDefaultItem(HMENU hmenu, UINT item, UINT bypos)
{
MENUITEM *menuitem = MENU_FindItem(&hmenu, &item, bypos);
POPUPMENU *menu;
@@ -4004,7 +4004,7 @@
/**********************************************************************
* GetMenuDefaultItem32 (USER32.260)
*/
-UINT32 WINAPI GetMenuDefaultItem32(HMENU32 hmenu, UINT32 bypos, UINT32 flags)
+UINT WINAPI GetMenuDefaultItem(HMENU hmenu, UINT bypos, UINT flags)
{
POPUPMENU *menu;
@@ -4030,7 +4030,7 @@
BOOL16 WINAPI InsertMenuItem16( HMENU16 hmenu, UINT16 pos, BOOL16 byposition,
const MENUITEMINFO16 *mii )
{
- MENUITEMINFO32A miia;
+ MENUITEMINFOA miia;
miia.cbSize = sizeof(miia);
miia.fMask = mii->fMask;
@@ -4045,41 +4045,41 @@
miia.cch = mii->cch;
if (IS_STRING_ITEM(miia.fType))
miia.dwTypeData = PTR_SEG_TO_LIN(miia.dwTypeData);
- return InsertMenuItem32A( hmenu, pos, byposition, &miia );
+ return InsertMenuItemA( hmenu, pos, byposition, &miia );
}
/**********************************************************************
* InsertMenuItem32A (USER32.323)
*/
-BOOL32 WINAPI InsertMenuItem32A(HMENU32 hMenu, UINT32 uItem, BOOL32 bypos,
- const MENUITEMINFO32A *lpmii)
+BOOL WINAPI InsertMenuItemA(HMENU hMenu, UINT uItem, BOOL bypos,
+ const MENUITEMINFOA *lpmii)
{
MENUITEM *item = MENU_InsertItem(hMenu, uItem, bypos ? MF_BYPOSITION : 0 );
- return SetMenuItemInfo32_common(item, lpmii, FALSE);
+ return SetMenuItemInfo_common(item, lpmii, FALSE);
}
/**********************************************************************
* InsertMenuItem32W (USER32.324)
*/
-BOOL32 WINAPI InsertMenuItem32W(HMENU32 hMenu, UINT32 uItem, BOOL32 bypos,
- const MENUITEMINFO32W *lpmii)
+BOOL WINAPI InsertMenuItemW(HMENU hMenu, UINT uItem, BOOL bypos,
+ const MENUITEMINFOW *lpmii)
{
MENUITEM *item = MENU_InsertItem(hMenu, uItem, bypos ? MF_BYPOSITION : 0 );
- return SetMenuItemInfo32_common(item, (const MENUITEMINFO32A*)lpmii, TRUE);
+ return SetMenuItemInfo_common(item, (const MENUITEMINFOA*)lpmii, TRUE);
}
/**********************************************************************
* CheckMenuRadioItem32 (USER32.47)
*/
-BOOL32 WINAPI CheckMenuRadioItem32(HMENU32 hMenu,
- UINT32 first, UINT32 last, UINT32 check,
- UINT32 bypos)
+BOOL WINAPI CheckMenuRadioItem(HMENU hMenu,
+ UINT first, UINT last, UINT check,
+ UINT bypos)
{
MENUITEM *mifirst, *milast, *micheck;
- HMENU32 mfirst = hMenu, mlast = hMenu, mcheck = hMenu;
+ HMENU mfirst = hMenu, mlast = hMenu, mcheck = hMenu;
TRACE(menu, "ox%x: %d-%d, check %d, bypos=%d\n",
hMenu, first, last, check, bypos);
@@ -4117,7 +4117,7 @@
UINT16 first, UINT16 last, UINT16 check,
BOOL16 bypos)
{
- return CheckMenuRadioItem32 (hMenu, first, last, check, bypos);
+ return CheckMenuRadioItem (hMenu, first, last, check, bypos);
}
/**********************************************************************
@@ -4128,12 +4128,12 @@
* always on the upper left side of the application.
*
*/
-BOOL32 WINAPI GetMenuItemRect32 (HWND32 hwnd, HMENU32 hMenu, UINT32 uItem,
- LPRECT32 rect)
+BOOL WINAPI GetMenuItemRect (HWND hwnd, HMENU hMenu, UINT uItem,
+ LPRECT rect)
{
POPUPMENU *itemMenu;
MENUITEM *item;
- HWND32 referenceHwnd;
+ HWND referenceHwnd;
TRACE(menu, "(0x%x,0x%x,%d,%p)\n", hwnd, hMenu, uItem, rect);
@@ -4156,7 +4156,7 @@
*rect = item->rect;
- MapWindowPoints32(referenceHwnd, 0, (LPPOINT32)rect, 2);
+ MapWindowPoints(referenceHwnd, 0, (LPPOINT)rect, 2);
return TRUE;
}
@@ -4168,11 +4168,11 @@
BOOL16 WINAPI GetMenuItemRect16 (HWND16 hwnd, HMENU16 hMenu, UINT16 uItem,
LPRECT16 rect)
{
- RECT32 r32;
- BOOL32 res;
+ RECT r32;
+ BOOL res;
if (!rect) return FALSE;
- res = GetMenuItemRect32 (hwnd, hMenu, uItem, &r32);
+ res = GetMenuItemRect (hwnd, hMenu, uItem, &r32);
CONV_RECT32TO16 (&r32, rect);
return res;
}
@@ -4182,14 +4182,14 @@
*/
BOOL16 WINAPI SetMenuContextHelpId16( HMENU16 hMenu, DWORD dwContextHelpId)
{
- return SetMenuContextHelpId32( hMenu, dwContextHelpId );
+ return SetMenuContextHelpId( hMenu, dwContextHelpId );
}
/**********************************************************************
* SetMenuContextHelpId32 (USER32.488)
*/
-BOOL32 WINAPI SetMenuContextHelpId32( HMENU32 hMenu, DWORD dwContextHelpId)
+BOOL WINAPI SetMenuContextHelpId( HMENU hMenu, DWORD dwContextHelpId)
{
FIXME(menu, "SetMenuContextHelpId, stub\n");
return 0;
@@ -4206,7 +4206,7 @@
/**********************************************************************
* GetMenuContextHelpId32 (USER32.488)
*/
-DWORD WINAPI GetMenuContextHelpId32( HMENU32 hMenu )
+DWORD WINAPI GetMenuContextHelpId( HMENU hMenu )
{
FIXME(menu, "GetMenuContextHelpId, stub\n");
return 0;