Huw Davies : comdlg32: We no longer need to update the dialog struct on exit as all of the information is up to date .

Alexandre Julliard julliard at winehq.org
Wed Jan 14 09:03:49 CST 2009


Module: wine
Branch: master
Commit: 8b10dd2a8daed738527f92aa89104c8647e4535c
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=8b10dd2a8daed738527f92aa89104c8647e4535c

Author: Huw Davies <huw at codeweavers.com>
Date:   Wed Jan 14 14:42:38 2009 +0000

comdlg32: We no longer need to update the dialog struct on exit as all of the information is up to date.

---

 dlls/comdlg32/printdlg.c |   49 ----------------------------------------------
 1 files changed, 0 insertions(+), 49 deletions(-)

diff --git a/dlls/comdlg32/printdlg.c b/dlls/comdlg32/printdlg.c
index 9669394..c7e7d60 100644
--- a/dlls/comdlg32/printdlg.c
+++ b/dlls/comdlg32/printdlg.c
@@ -2568,53 +2568,6 @@ end:
     return retval;
 }
 
-/****************************************************************************
- * PRINTDLG_PS_UpdateDlgStructA
- *
- * Updates pda->dlga structure 
- * Function calls when user presses OK button
- *
- * PARAMS
- *  hDlg	[in] 	 main window dialog HANDLE
- *  pda 	[in/out] ptr to PageSetupDataA structure
- *
- * RETURNS
- *  TRUE
- */
-static BOOL
-PRINTDLG_PS_UpdateDlgStructA(HWND hDlg, PageSetupDataA *pda) {
-    DEVMODEA	*dm;
-    DWORD 	paperword;
-
-    dm = GlobalLock(pda->dlga->hDevMode);
-
-    /* Save paper orientation into device context */
-    if(pda->dlga->ptPaperSize.x > pda->dlga->ptPaperSize.y)
-        dm->u1.s1.dmOrientation = DMORIENT_LANDSCAPE;
-    else
-        dm->u1.s1.dmOrientation = DMORIENT_PORTRAIT;
-
-    /* Save paper size into the device context */
-    paperword = SendDlgItemMessageA(hDlg,cmb2,CB_GETITEMDATA,
-        SendDlgItemMessageA(hDlg, cmb2, CB_GETCURSEL, 0, 0), 0);
-    if (paperword != CB_ERR)
-        dm->u1.s1.dmPaperSize = paperword;
-    else
-        FIXME("could not get dialog text for papersize cmbbox?\n");
-
-    /* Save paper source into the device context */
-    paperword = SendDlgItemMessageA(hDlg,cmb1,CB_GETITEMDATA,
-        SendDlgItemMessageA(hDlg, cmb1, CB_GETCURSEL, 0, 0), 0);
-    if (paperword != CB_ERR)
-        dm->u1.s1.dmDefaultSource = paperword;
-    else
-        FIXME("could not get dialog text for papersize cmbbox?\n");
-
-    GlobalUnlock(pda->dlga->hDevMode);
-
-    return TRUE;
-}
-
 static BOOL
 PRINTDLG_PS_UpdateDlgStructW(HWND hDlg, PageSetupDataW *pdw) {
     DEVNAMES	*dn;
@@ -2898,8 +2851,6 @@ PRINTDLG_PS_WMCommandA(
 	    LOWORD(lParam),wParam,lParam);
     switch (id)  {
     case IDOK:
-        if (!PRINTDLG_PS_UpdateDlgStructA(hDlg, pda))
-	    return(FALSE);
 	EndDialog(hDlg, TRUE);
 	return TRUE ;
 




More information about the wine-cvs mailing list