Changeset 3482 for trunk/src/user32/win32dlg.cpp
- Timestamp:
- May 2, 2000, 10:50:53 PM (25 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/win32dlg.cpp
r3060 r3482 1 /* $Id: win32dlg.cpp,v 1.4 7 2000-03-09 19:05:39sandervl Exp $ */1 /* $Id: win32dlg.cpp,v 1.48 2000-05-02 20:50:51 sandervl Exp $ */ 2 2 /* 3 3 * Win32 Dialog Code for OS/2 … … 76 76 if (dlgInfo.style & DS_SETFONT) 77 77 { 78 /* The font height must be negative as it is a point size */ 79 /* (see CreateFont() documentation in the Windows SDK). */ 80 hUserFont = CreateFontW(-(dlgInfo.pointSize*3)/2, 0, 0, 0, 78 /* The font height must be negative as it is a point size */ 79 /* and must be converted to pixels first */ 80 /* (see CreateFont() documentation in the Windows SDK). */ 81 HDC dc = GetDC(0); 82 int pixels = dlgInfo.pointSize * GetDeviceCaps(dc , LOGPIXELSY)/72; 83 ReleaseDC(0, dc); 84 85 hUserFont = CreateFontW(-pixels, 0, 0, 0, 81 86 dlgInfo.weight, dlgInfo.italic, FALSE, 82 87 FALSE, DEFAULT_CHARSET, 0, 0, PROOF_QUALITY, … … 125 130 INT dX, dY; 126 131 127 if( !(dlgInfo.style & DS_ABSALIGN) )132 if( !(dlgInfo.style & DS_ABSALIGN) && owner) 128 133 ClientToScreen(owner, (POINT *)&rect ); 129 134 … … 232 237 hwndFocus = GetNextDlgTabItem( getWindowHandle(), 0, FALSE ); 233 238 234 if (SendInternalMessageA(WM_INITDIALOG, (WPARAM)hwndFocus, param)) 235 SetFocus(hwndFocus); 239 HWND hwndPreInitFocus = GetFocus(); 240 if(SendInternalMessageA(WM_INITDIALOG, (WPARAM)hwndFocus, param)) { 241 SetFocus(hwndFocus); 242 } 243 else 244 { 245 /* If the dlgproc has returned FALSE (indicating handling of keyboard focus) 246 but the focus has not changed, set the focus where we expect it. */ 247 if ( (getStyle() & WS_VISIBLE) && ( GetFocus() == hwndPreInitFocus ) ) 248 SetFocus( hwndFocus ); 249 } 236 250 237 251 if (dlgInfo.style & WS_VISIBLE && !(getStyle() & WS_VISIBLE))
Note:
See TracChangeset
for help on using the changeset viewer.