diff --git a/windows/defdlg.c b/windows/defdlg.c
new file mode 100644
index 0000000..8405dc3
--- /dev/null
+++ b/windows/defdlg.c
@@ -0,0 +1,76 @@
+/*
+ * Default dialog procedure
+ *
+ * Copyright 1993 Alexandre Julliard
+ */
+
+static char Copyright[] = "Copyright  Alexandre Julliard, 1993";
+
+#include "windows.h"
+#include "dialog.h"
+#include "win.h"
+
+
+/***********************************************************************
+ *           DefDlgProc   (USER.308)
+ */
+LONG DefDlgProc( HWND hwnd, WORD msg, WORD wParam, LONG lParam )
+{
+    DIALOGINFO * dlgInfo;
+    BOOL result = FALSE;
+    WND * wndPtr = WIN_FindWndPtr( hwnd );
+    
+    if (!wndPtr) return 0;
+    dlgInfo = (DIALOGINFO *)&wndPtr->wExtra;
+
+#ifdef DEBUG_DIALOG
+    printf( "DefDlgProc: %d %04x %d %08x\n", hwnd, msg, wParam, lParam );
+#endif
+
+    dlgInfo->msgResult = 0;
+    if (dlgInfo->dlgProc)
+    {
+	  /* Call dialog procedure */
+	result = (BOOL)CallWindowProc( dlgInfo->dlgProc, hwnd, 
+				       msg, wParam, lParam );
+
+	  /* Check if window destroyed by dialog procedure */
+	wndPtr = WIN_FindWndPtr( hwnd );
+	if (!wndPtr) return result;
+    }
+    
+    if (!result) switch(msg)
+    {
+	case WM_INITDIALOG:
+	    break;
+
+        case WM_ERASEBKGND:
+	    FillWindow( hwnd, hwnd, (HDC)wParam, (HBRUSH)CTLCOLOR_DLG );
+	    return TRUE;
+
+	case WM_NCDESTROY:
+
+	      /* Delete font */
+	    if (dlgInfo->hUserFont)
+	    {
+		DeleteObject( dlgInfo->hUserFont );
+		dlgInfo->hUserFont = 0;
+	    }
+
+	      /* Delete menu */
+	    if (dlgInfo->hMenu)
+	    {		
+		DestroyMenu( dlgInfo->hMenu );
+		dlgInfo->hMenu = 0;
+	    }
+
+	      /* Window clean-up */
+	    DefWindowProc( hwnd, msg, wParam, lParam );
+	    break;
+	    
+	default:
+	    return DefWindowProc( hwnd, msg, wParam, lParam );
+    }
+        
+    return result;
+}
