Commit 87b81de0 authored by Francois Boisvert's avatar Francois Boisvert Committed by Alexandre Julliard

Implemented the Win95 file open/save dialogs.

parent 4d088fa9
...@@ -13,6 +13,8 @@ C_SRCS = \ ...@@ -13,6 +13,8 @@ C_SRCS = \
cdlg32.c \ cdlg32.c \
colordlg.c \ colordlg.c \
filedlg.c \ filedlg.c \
filedlg95.c \
filedlgbrowser.c \
finddlg.c \ finddlg.c \
finddlg32.c \ finddlg32.c \
filetitle.c \ filetitle.c \
......
...@@ -36,5 +36,16 @@ typedef struct { ...@@ -36,5 +36,16 @@ typedef struct {
} user_fr; } user_fr;
} COMDLG32_FR_Data; } COMDLG32_FR_Data;
#include "commctrl.h"
extern HDPA (WINAPI* COMDLG32_DPA_Create) (INT);
extern LPVOID (WINAPI* COMDLG32_DPA_GetPtr) (const HDPA, INT);
extern LPVOID (WINAPI* COMDLG32_DPA_DeleteAllPtrs) (const HDPA hdpa);
extern LPVOID (WINAPI* COMDLG32_DPA_DeletePtr) (const HDPA hdpa, INT i);
extern INT (WINAPI* COMDLG32_DPA_InsertPtr) (const HDPA, INT, LPVOID);
extern BOOL (WINAPI* COMDLG32_DPA_Destroy) (const HDPA);
extern HICON (WINAPI* COMDLG32_ImageList_GetIcon) (HIMAGELIST, INT, UINT);
extern HIMAGELIST (WINAPI *COMDLG32_ImageList_LoadImageA) (HINSTANCE, LPCSTR, INT, INT, COLORREF, UINT, UINT);
extern BOOL (WINAPI* COMDLG32_ImageList_Draw) (HIMAGELIST himl, int i, HDC hdcDest, int x, int y, UINT fStyle);
#endif #endif
...@@ -21,6 +21,18 @@ HINSTANCE16 COMDLG32_hInstance16 = 0; ...@@ -21,6 +21,18 @@ HINSTANCE16 COMDLG32_hInstance16 = 0;
static DWORD COMDLG32_TlsIndex; static DWORD COMDLG32_TlsIndex;
static int COMDLG32_Attach = 0; static int COMDLG32_Attach = 0;
HINSTANCE COMCTL32_hInstance = 0;
HDPA (WINAPI* COMDLG32_DPA_Create) (INT);
LPVOID (WINAPI* COMDLG32_DPA_GetPtr) (const HDPA, INT);
LPVOID (WINAPI* COMDLG32_DPA_DeletePtr) (const HDPA hdpa, INT i);
LPVOID (WINAPI* COMDLG32_DPA_DeleteAllPtrs) (const HDPA hdpa);
INT (WINAPI* COMDLG32_DPA_InsertPtr) (const HDPA, INT, LPVOID);
BOOL (WINAPI* COMDLG32_DPA_Destroy) (const HDPA);
HICON (WINAPI* COMDLG32_ImageList_GetIcon) (HIMAGELIST, INT, UINT);
HIMAGELIST (WINAPI *COMDLG32_ImageList_LoadImageA) (HINSTANCE, LPCSTR, INT, INT, COLORREF, UINT, UINT);
BOOL (WINAPI* COMDLG32_ImageList_Draw) (HIMAGELIST himl, int i, HDC hdcDest, int x, int y, UINT fStyle);
/*********************************************************************** /***********************************************************************
* COMDLG32_DllEntryPoint (COMDLG32.entry) * COMDLG32_DllEntryPoint (COMDLG32.entry)
* *
...@@ -66,6 +78,19 @@ BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Res ...@@ -66,6 +78,19 @@ BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Res
ERR("No space for COMDLG32 TLS\n"); ERR("No space for COMDLG32 TLS\n");
return FALSE; return FALSE;
} }
COMCTL32_hInstance = LoadLibraryA("COMCTL32.DLL");
COMDLG32_DPA_Create=(void*)GetProcAddress(COMCTL32_hInstance, (LPCSTR)328L);
COMDLG32_DPA_Destroy=(void*)GetProcAddress(COMCTL32_hInstance, (LPCSTR)329L);
COMDLG32_DPA_GetPtr=(void*)GetProcAddress(COMCTL32_hInstance, (LPCSTR)332L);
COMDLG32_DPA_InsertPtr=(void*)GetProcAddress(COMCTL32_hInstance, (LPCSTR)334L);
COMDLG32_DPA_DeletePtr=(void*)GetProcAddress(COMCTL32_hInstance, (LPCSTR)336L);
COMDLG32_DPA_DeleteAllPtrs=(void*)GetProcAddress(COMCTL32_hInstance, (LPCSTR)337L);
COMDLG32_ImageList_GetIcon=(void*)GetProcAddress(COMCTL32_hInstance,"ImageList_GetIcon");
COMDLG32_ImageList_LoadImageA=(void*)GetProcAddress(COMCTL32_hInstance,"ImageList_LoadImageA");
COMDLG32_ImageList_Draw=(void*)GetProcAddress(COMCTL32_hInstance,"ImageList_Draw");
break; break;
case DLL_PROCESS_DETACH: case DLL_PROCESS_DETACH:
...@@ -75,6 +100,8 @@ BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Res ...@@ -75,6 +100,8 @@ BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Res
COMDLG32_hInstance = 0; COMDLG32_hInstance = 0;
if(COMDLG32_hInstance16) if(COMDLG32_hInstance16)
FreeLibrary16(COMDLG32_hInstance16); FreeLibrary16(COMDLG32_hInstance16);
FreeLibrary(COMCTL32_hInstance);
} }
break; break;
} }
......
...@@ -195,7 +195,6 @@ FONT 8, "Helv" ...@@ -195,7 +195,6 @@ FONT 8, "Helv"
} }
PRINT32 DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 186 PRINT32 DIALOG LOADONCALL MOVEABLE DISCARDABLE 32, 32, 288, 186
STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU |
DS_CONTEXTHELP | DS_3DLOOK DS_CONTEXTHELP | DS_3DLOOK
...@@ -236,3 +235,124 @@ FONT 8, "Helv" ...@@ -236,3 +235,124 @@ FONT 8, "Helv"
RTEXT "&to:", stc3, 100,124, 16,8 RTEXT "&to:", stc3, 100,124, 16,8
} }
IDD_OPENDIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 280, 159
STYLE DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Open"
FONT 8, "helv"
{
DEFPUSHBUTTON "&Open", IDOK,219,111,50,14
PUSHBUTTON "Cancel", IDCANCEL,219,128,50,14
CONTROL "Open as &read-only",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,109,9
COMBOBOX IDC_FILETYPE,54,128,157,102,CBS_DROPDOWN | WS_VSCROLL | WS_TABSTOP
EDITTEXT IDC_FILENAME,54,110,158,15,ES_AUTOHSCROLL
LTEXT "File &name:",IDC_FILENAMESTATIC,3,111,36,10
LTEXT "Files of &type",IDC_FILETYPESTATIC,3,128,41,10
LTEXT "", IDC_SHELLSTATIC,3,21,273,84,SS_SUNKEN | NOT WS_VISIBLE | NOT WS_GROUP |WS_EX_TRANSPARENT
LTEXT "Look &in",IDC_LOOKINSTATIC,3,5,29,10
COMBOBOX IDC_LOOKIN,50,1,137,93,CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP
PUSHBUTTON "Up",IDC_UPFOLDER,194,1,15,15,BS_ICON | BS_CENTER | BS_VCENTER
PUSHBUTTON "New",IDC_NEWFOLDER,213,1,15,15,BS_ICON | BS_CENTER | BS_VCENTER
CONTROL "I",IDC_LIST,"Button",BS_AUTORADIOBUTTON | BS_ICON | BS_CENTER | BS_VCENTER | BS_PUSHLIKE,233,1,15,15
CONTROL "L",IDC_DETAILS,"Button",BS_AUTORADIOBUTTON | BS_ICON | BS_CENTER | BS_VCENTER | BS_PUSHLIKE,249,1,15,15
}
IDD_SAVEDIALOG DIALOG LOADONCALL MOVEABLE DISCARDABLE 0, 0, 280, 159
STYLE DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Save As"
FONT 8, "helv"
{
DEFPUSHBUTTON "&Save", IDOK,219,111,50,14
PUSHBUTTON "Cancel", IDCANCEL,219,128,50,14
CONTROL "Open as &read-only",IDC_OPENREADONLY,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,54,145,109,9
COMBOBOX IDC_FILETYPE,54,128,157,102,CBS_DROPDOWN | WS_VSCROLL | WS_TABSTOP
EDITTEXT IDC_FILENAME,54,110,158,15,ES_AUTOHSCROLL
LTEXT "File &name:",IDC_FILENAMESTATIC,3,111,36,10
LTEXT "Save as &type",IDC_FILETYPESTATIC,3,128,41,10
LTEXT "", IDC_SHELLSTATIC,3,21,273,84,SS_SUNKEN | NOT WS_VISIBLE | NOT WS_GROUP |WS_EX_TRANSPARENT
LTEXT "Save &in",IDC_LOOKINSTATIC,3,5,29,10
COMBOBOX IDC_LOOKIN,50,1,137,93,CBS_DROPDOWNLIST | CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | WS_VSCROLL | WS_TABSTOP
PUSHBUTTON "Up",IDC_UPFOLDER,194,1,15,15,BS_ICON | BS_CENTER | BS_VCENTER
PUSHBUTTON "New",IDC_NEWFOLDER,213,1,15,15,BS_ICON | BS_CENTER | BS_VCENTER
CONTROL "I",IDC_LIST,"Button",BS_AUTORADIOBUTTON | BS_ICON | BS_CENTER | BS_VCENTER | BS_PUSHLIKE,233,1,15,15
CONTROL "L",IDC_DETAILS,"Button",BS_AUTORADIOBUTTON | BS_ICON | BS_CENTER | BS_VCENTER | BS_PUSHLIKE,249,1,15,15
}
STRINGTABLE DISCARDABLE
{
IDS_ABOUTBOX "&About FolderPicker Test"
IDS_DOCUMENTFOLDERS "Document Folders"
IDS_PERSONAL "My Documents"
IDS_FAVORITES "My Favorites"
IDS_PATH "System Path"
IDS_DESKTOP "Desktop"
IDS_FONTS "Fonts"
IDS_MYCOMPUTER "My Computer"
}
STRINGTABLE DISCARDABLE
{
IDS_SYSTEMFOLDERS "System Folders"
IDS_LOCALHARDRIVES "Local Hard Drives"
IDS_FILENOTFOUND "File not found"
IDS_VERIFYFILE "Please verify if the correct file name was given"
IDS_CREATEFILE "File does not exist\nDo you want to create file"
}
/******************
* Bitmap
*/
IDB_TOOLBAR BITMAP DISCARDABLE
{'
42 4d b6 02 00 00 00 00 00 00 76 00 00 00 28 00
00 00 41 00 00 00 10 00 00 00 01 00 04 00 00 00
00 00 40 02 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 80 00 00 80
00 00 00 80 80 00 80 00 00 00 80 00 80 00 80 80
00 00 c0 c0 c0 00 80 80 80 00 00 00 ff 00 00 ff
00 00 00 ff ff 00 ff 00 00 00 ff 00 ff 00 ff ff
00 00 ff ff ff 00 aa aa aa aa aa aa aa aa aa aa
aa aa aa aa aa aa aa aa aa aa aa aa aa aa aa aa
aa aa aa aa aa aa a3 00 b6 01 aa aa aa 88 88 8a
aa aa 00 00 00 00 00 0a aa aa 44 4a aa aa aa aa
aa aa 88 80 00 0f 00 0f 00 0f ab 00 db 02 aa aa
a0 00 00 8a aa aa 0b bb bb bb bb 0a aa aa 4f 4a
00 0a aa aa aa aa f7 8f ff ff ff ff ff ff a9 02
2a 02 aa aa a0 77 70 8a aa aa 0b bb bb bb bb 9a
aa aa 44 aa aa aa aa aa aa aa f7 80 00 0f 00 0f
00 0f a2 00 02 00 aa aa a0 77 70 8a aa aa 0b bb
bb bb bb 9a aa aa aa aa aa aa aa aa aa aa f7 8f
ff ff ff ff ff ff a4 f8 15 00 aa aa a0 77 70 8a
aa aa 0b bb bb b9 bb 9a a9 aa aa aa aa aa aa aa
aa aa f7 80 00 0f 00 0f 00 0f a2 00 02 00 aa aa
a0 77 70 8a aa aa 0b bb bb bb 9b 9a 9a aa 44 4a
aa aa 44 4a aa aa f7 8f ff ff ff ff ff ff a0 00
ad 00 aa aa a0 77 70 8a aa aa 0b bb bb bb b9 99
aa aa 4f 4a 00 0a 4f 4a 00 0a f7 80 00 0f 00 0f
00 0f a1 00 b5 00 aa aa a0 77 70 88 8a aa 00 00
00 99 99 99 99 9a 44 aa aa aa 44 aa aa aa f7 8f
ff ff ff ff ff ff ad 01 0b 02 aa 00 00 77 70 00
0a aa a0 bb bb 0a a9 99 aa aa aa aa aa aa aa aa
aa aa f7 80 00 0f 00 0f 00 0f a9 01 5d 01 aa a0
f7 77 77 70 aa aa aa 00 00 aa 9a 9a 9a aa aa aa
aa aa aa aa aa aa f7 8f ff ff ff ff ff ff a0 01
63 01 aa aa 0f 77 77 0a aa aa aa aa aa a9 aa 9a
a9 aa 44 4a aa aa 44 4a aa aa 88 88 88 88 88 88
88 88 ab 01 0f 01 aa aa a0 f7 70 aa aa aa aa aa
aa aa aa 9a aa aa 4f 4a 00 0a 4f 4a 00 0a f7 8f
77 78 f7 78 f7 78 a8 01 7d 01 aa aa aa 0f 0a aa
aa aa aa aa aa aa aa 9a aa aa 44 aa aa aa 44 aa
aa aa f7 8f 77 78 f7 78 f7 78 ae 01 62 02 aa aa
aa a0 aa aa aa aa aa aa aa aa aa 9a aa aa aa aa
aa aa aa aa aa aa ff ff ff ff ff ff ff f7 a2 01
b9 01 aa aa aa aa aa aa aa aa aa aa aa aa aa aa
aa aa aa aa aa aa aa aa aa aa aa aa aa aa aa aa
aa aa a2 00 43 02'}
...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
* Copyright 1994 Martin Ayotte * Copyright 1994 Martin Ayotte
* Copyright 1996 Albrecht Kleine * Copyright 1996 Albrecht Kleine
*/ */
#include <ctype.h> #include <ctype.h>
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
...@@ -22,6 +21,7 @@ ...@@ -22,6 +21,7 @@
#include "debugtools.h" #include "debugtools.h"
#include "winproc.h" #include "winproc.h"
#include "cderr.h" #include "cderr.h"
#include "tweak.h"
DEFAULT_DEBUG_CHANNEL(commdlg) DEFAULT_DEBUG_CHANNEL(commdlg)
...@@ -39,6 +39,11 @@ static int fldrWidth = 0; ...@@ -39,6 +39,11 @@ static int fldrWidth = 0;
static const char defaultfilter[]=" \0\0"; static const char defaultfilter[]=" \0\0";
/*********************************************************************** /***********************************************************************
*
* Windows 3.1 OpenFileName/SaveFileName dialog
*
*/
/***********************************************************************
* FileDlg_Init [internal] * FileDlg_Init [internal]
*/ */
static BOOL FileDlg_Init(void) static BOOL FileDlg_Init(void)
...@@ -1033,9 +1038,8 @@ static LRESULT FILEDLG_WMCommand(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam) ...@@ -1033,9 +1038,8 @@ static LRESULT FILEDLG_WMCommand(HWND16 hWnd, WPARAM16 wParam, LPARAM lParam)
return FALSE; return FALSE;
} }
/*********************************************************************** /***********************************************************************
* FileOpenDlgProc (COMMDLG.6) * FileOpenDlgProc16 (COMMDLG.6)
*/ */
LRESULT WINAPI FileOpenDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam, LRESULT WINAPI FileOpenDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam,
LPARAM lParam) LPARAM lParam)
...@@ -1077,9 +1081,8 @@ LRESULT WINAPI FileOpenDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam, ...@@ -1077,9 +1081,8 @@ LRESULT WINAPI FileOpenDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam,
return FALSE; return FALSE;
} }
/*********************************************************************** /***********************************************************************
* FileSaveDlgProc (COMMDLG.7) * FileSaveDlgProc16 (COMMDLG.7)
*/ */
LRESULT WINAPI FileSaveDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam, LRESULT WINAPI FileSaveDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam,
LPARAM lParam) LPARAM lParam)
...@@ -1125,8 +1128,6 @@ LRESULT WINAPI FileSaveDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam, ...@@ -1125,8 +1128,6 @@ LRESULT WINAPI FileSaveDlgProc16(HWND16 hWnd, UINT16 wMsg, WPARAM16 wParam,
return FALSE; return FALSE;
} }
static BOOL Commdlg_GetFileNameA( BOOL16 (CALLBACK *dofunction)(SEGPTR x), static BOOL Commdlg_GetFileNameA( BOOL16 (CALLBACK *dofunction)(SEGPTR x),
LPOPENFILENAMEA ofn ) LPOPENFILENAMEA ofn )
{ {
...@@ -1352,7 +1353,6 @@ static BOOL Commdlg_GetFileNameW( BOOL16 (CALLBACK *dofunction)(SEGPTR x), ...@@ -1352,7 +1353,6 @@ static BOOL Commdlg_GetFileNameW( BOOL16 (CALLBACK *dofunction)(SEGPTR x),
SEGPTR_FREE(ofn16); SEGPTR_FREE(ofn16);
return ret; return ret;
} }
/*********************************************************************** /***********************************************************************
* GetOpenFileNameA (COMDLG32.10) * GetOpenFileNameA (COMDLG32.10)
* *
...@@ -1369,9 +1369,16 @@ BOOL WINAPI GetOpenFileNameA( ...@@ -1369,9 +1369,16 @@ BOOL WINAPI GetOpenFileNameA(
LPOPENFILENAMEA ofn /* address of init structure */ LPOPENFILENAMEA ofn /* address of init structure */
) )
{ {
if(TWEAK_WineLook > WIN31_LOOK)
{
return GetFileDialog95A(ofn, OPEN_DIALOG);
}
else
{
BOOL16 (CALLBACK * dofunction)(SEGPTR ofn16) = GetOpenFileName16; BOOL16 (CALLBACK * dofunction)(SEGPTR ofn16) = GetOpenFileName16;
return Commdlg_GetFileNameA(dofunction,ofn); return Commdlg_GetFileNameA(dofunction,ofn);
} }
}
/*********************************************************************** /***********************************************************************
* GetOpenFileNameW (COMDLG32.11) * GetOpenFileNameW (COMDLG32.11)
...@@ -1389,9 +1396,16 @@ BOOL WINAPI GetOpenFileNameW( ...@@ -1389,9 +1396,16 @@ BOOL WINAPI GetOpenFileNameW(
LPOPENFILENAMEW ofn /* address of init structure */ LPOPENFILENAMEW ofn /* address of init structure */
) )
{ {
if(TWEAK_WineLook > WIN31_LOOK)
{
return GetFileDialog95W(ofn, OPEN_DIALOG);
}
else
{
BOOL16 (CALLBACK * dofunction)(SEGPTR ofn16) = GetOpenFileName16; BOOL16 (CALLBACK * dofunction)(SEGPTR ofn16) = GetOpenFileName16;
return Commdlg_GetFileNameW(dofunction,ofn); return Commdlg_GetFileNameW(dofunction,ofn);
} }
}
/*********************************************************************** /***********************************************************************
* GetSaveFileNameA (COMDLG32.12) * GetSaveFileNameA (COMDLG32.12)
...@@ -1409,10 +1423,18 @@ BOOL WINAPI GetSaveFileNameA( ...@@ -1409,10 +1423,18 @@ BOOL WINAPI GetSaveFileNameA(
LPOPENFILENAMEA ofn /* address of init structure */ LPOPENFILENAMEA ofn /* address of init structure */
) )
{ {
if(TWEAK_WineLook > WIN31_LOOK)
{
return GetFileDialog95A(ofn, SAVE_DIALOG);
}
else
{
BOOL16 (CALLBACK * dofunction)(SEGPTR ofn16) = GetSaveFileName16; BOOL16 (CALLBACK * dofunction)(SEGPTR ofn16) = GetSaveFileName16;
return Commdlg_GetFileNameA(dofunction,ofn); return Commdlg_GetFileNameA(dofunction,ofn);
} }
}
/*********************************************************************** /***********************************************************************
* GetSaveFileNameW (COMDLG32.13) * GetSaveFileNameW (COMDLG32.13)
* *
...@@ -1429,7 +1451,14 @@ BOOL WINAPI GetSaveFileNameW( ...@@ -1429,7 +1451,14 @@ BOOL WINAPI GetSaveFileNameW(
LPOPENFILENAMEW ofn /* address of init structure */ LPOPENFILENAMEW ofn /* address of init structure */
) )
{ {
if(TWEAK_WineLook > WIN31_LOOK)
{
return GetFileDialog95W(ofn, SAVE_DIALOG);
}
else
{
BOOL16 (CALLBACK * dofunction)(SEGPTR ofn16) = GetSaveFileName16; BOOL16 (CALLBACK * dofunction)(SEGPTR ofn16) = GetSaveFileName16;
return Commdlg_GetFileNameW(dofunction,ofn); return Commdlg_GetFileNameW(dofunction,ofn);
} }
}
/*
* Implementation of IShellBrowser for the File Open common dialog
*
*
*/
#ifndef SHBROWSER_H
#define SHBROWSER_H TRUE
#include "shlobj.h"
#include "winbase.h"
#include "objbase.h"
#include "commdlg.h"
/***********************************************************************
* Defines and global variables
*/
#define _ICOM_THIS_FromICommDlgBrowser(Class,name) Class* This = (Class*) (((char*)name)-sizeof(void *))
/***********************************************************************
* Data structure
*/
typedef struct
{
ICOM_VTABLE(IShellBrowser)* lpVtbl; /* IShellBrowser VTable */
ICOM_VTABLE(ICommDlgBrowser)* lpVtbl2; /* ICommDlgBrowser VTable */
DWORD ref; /* Reference counter */
HWND hwndOwner; /* Owner dialog of the interface */
} IShellBrowserImpl;
typedef struct
{
OPENFILENAMEA ofnInfos;
struct {
IShellBrowser *FOIShellBrowser;
IShellFolder *FOIShellFolder;
IShellView *FOIShellView;
} Shell;
struct {
HWND hwndOwner;
HWND hwndView;
RECT rectView;
FOLDERSETTINGS folderSettings;
LPITEMIDLIST pidlAbsCurrent;
LPWSTR lpstrCurrentFilter;
} ShellInfos;
struct {
HWND hwndFileTypeCB;
HWND hwndLookInCB;
HWND hwndFileName;
} DlgInfos;
} FileOpenDlgInfos;
/***********************************************************************
* Prototypes for the methods of the IShellBrowserImpl class
*/
/* Constructor */
IShellBrowser * IShellBrowserImpl_Construct(HWND hwndOwner);
/* IUnknown */
HRESULT WINAPI IShellBrowserImpl_QueryInterface(IShellBrowser *iface,
REFIID riid,
LPVOID *ppvObj);
ULONG WINAPI IShellBrowserImpl_AddRef(IShellBrowser * iface);
ULONG WINAPI IShellBrowserImpl_Release(IShellBrowser * iface);
/* IOleWindow */
HRESULT WINAPI IShellBrowserImpl_GetWindow(IShellBrowser * iface,
HWND * phwnd);
HRESULT WINAPI IShellBrowserImpl_ContextSensitiveHelp(IShellBrowser * iface,
BOOL fEnterMode);
/* IShellBrowser */
HRESULT WINAPI IShellBrowserImpl_BrowseObject(IShellBrowser *iface,
LPCITEMIDLIST pidl,
UINT wFlags);
HRESULT WINAPI IShellBrowserImpl_EnableModelessSB(IShellBrowser *iface,
BOOL fEnable);
HRESULT WINAPI IShellBrowserImpl_GetControlWindow(IShellBrowser *iface,
UINT id,
HWND *lphwnd);
HRESULT WINAPI IShellBrowserImpl_GetViewStateStream(IShellBrowser *iface,
DWORD grfMode,
LPSTREAM *ppStrm);
HRESULT WINAPI IShellBrowserImpl_InsertMenusSB(IShellBrowser *iface,
HMENU hmenuShared,
LPOLEMENUGROUPWIDTHS lpMenuWidths);
HRESULT WINAPI IShellBrowserImpl_OnViewWindowActive(IShellBrowser *iface,
IShellView *ppshv);
HRESULT WINAPI IShellBrowserImpl_QueryActiveShellView(IShellBrowser *iface,
IShellView **ppshv);
HRESULT WINAPI IShellBrowserImpl_RemoveMenusSB(IShellBrowser *iface,
HMENU hmenuShared);
HRESULT WINAPI IShellBrowserImpl_SendControlMsg(IShellBrowser *iface,
UINT id,
UINT uMsg,
WPARAM wParam,
LPARAM lParam,
LRESULT *pret);
HRESULT WINAPI IShellBrowserImpl_SetMenuSB(IShellBrowser *iface,
HMENU hmenuShared,
HOLEMENU holemenuReserved,
HWND hwndActiveObject);
HRESULT WINAPI IShellBrowserImpl_SetStatusTextSB(IShellBrowser *iface,
LPCOLESTR lpszStatusText);
HRESULT WINAPI IShellBrowserImpl_SetToolbarItems(IShellBrowser *iface,
LPTBBUTTON lpButtons,
UINT nButtons,
UINT uFlags);
HRESULT WINAPI IShellBrowserImpl_TranslateAcceleratorSB(IShellBrowser *iface,
LPMSG lpmsg,
WORD wID);
/* ICommDlgBrowser */
HRESULT WINAPI IShellBrowserImpl_ICommDlgBrowser_QueryInterface(ICommDlgBrowser *iface,
REFIID riid,
LPVOID *ppvObj);
ULONG WINAPI IShellBrowserImpl_ICommDlgBrowser_AddRef(ICommDlgBrowser * iface);
ULONG WINAPI IShellBrowserImpl_ICommDlgBrowser_Release(ICommDlgBrowser * iface);
HRESULT WINAPI IShellBrowserImpl_ICommDlgBrowser_OnDefaultCommand(ICommDlgBrowser *iface,
IShellView *ppshv);
HRESULT WINAPI IShellBrowserImpl_ICommDlgBrowser_OnStateChange(ICommDlgBrowser *iface,
IShellView *ppshv,
ULONG uChange);
HRESULT WINAPI IShellBrowserImpl_ICommDlgBrowser_IncludeObject(ICommDlgBrowser *iface,
IShellView * ppshv,
LPCITEMIDLIST pidl);
#endif /*SHBROWSER_H*/
...@@ -44,6 +44,9 @@ extern "C" { ...@@ -44,6 +44,9 @@ extern "C" {
#define OFN_SHARENOWARN 1 #define OFN_SHARENOWARN 1
#define OFN_SHAREWARN 0 #define OFN_SHAREWARN 0
#define SAVE_DIALOG 1
#define OPEN_DIALOG 2
typedef UINT16 (CALLBACK *LPOFNHOOKPROC16)(HWND16,UINT16,WPARAM16,LPARAM); typedef UINT16 (CALLBACK *LPOFNHOOKPROC16)(HWND16,UINT16,WPARAM16,LPARAM);
typedef UINT (CALLBACK *LPOFNHOOKPROC)(HWND,UINT,WPARAM,LPARAM); typedef UINT (CALLBACK *LPOFNHOOKPROC)(HWND,UINT,WPARAM,LPARAM);
...@@ -591,7 +594,6 @@ BOOL WINAPI ChooseColorA(LPCHOOSECOLORA lpChCol); ...@@ -591,7 +594,6 @@ BOOL WINAPI ChooseColorA(LPCHOOSECOLORA lpChCol);
BOOL WINAPI ChooseColorW(LPCHOOSECOLORW lpChCol); BOOL WINAPI ChooseColorW(LPCHOOSECOLORW lpChCol);
#define ChooseColor WINELIB_NAME_AW(ChooseColor) #define ChooseColor WINELIB_NAME_AW(ChooseColor)
DWORD WINAPI CommDlgExtendedError(void); DWORD WINAPI CommDlgExtendedError(void);
DWORD WINAPI CommDlgExtendedError16(void);
HWND16 WINAPI FindText16( SEGPTR find); HWND16 WINAPI FindText16( SEGPTR find);
HWND WINAPI FindTextA(LPFINDREPLACEA lpFind); HWND WINAPI FindTextA(LPFINDREPLACEA lpFind);
HWND WINAPI FindTextW(LPFINDREPLACEW lpFind); HWND WINAPI FindTextW(LPFINDREPLACEW lpFind);
...@@ -603,6 +605,8 @@ INT16 WINAPI GetFileTitleW(LPCWSTR lpFile, LPWSTR lpTitle, UINT cbBuf); ...@@ -603,6 +605,8 @@ INT16 WINAPI GetFileTitleW(LPCWSTR lpFile, LPWSTR lpTitle, UINT cbBuf);
BOOL16 WINAPI GetOpenFileName16(SEGPTR ofn); BOOL16 WINAPI GetOpenFileName16(SEGPTR ofn);
BOOL WINAPI GetOpenFileNameA(LPOPENFILENAMEA ofn); BOOL WINAPI GetOpenFileNameA(LPOPENFILENAMEA ofn);
BOOL WINAPI GetOpenFileNameW(LPOPENFILENAMEW ofn); BOOL WINAPI GetOpenFileNameW(LPOPENFILENAMEW ofn);
BOOL WINAPI GetFileDialog95A(LPOPENFILENAMEA ofn,UINT iDlgType);
BOOL WINAPI GetFileDialog95W(LPOPENFILENAMEW ofn,UINT iDlgType);
#define GetOpenFileName WINELIB_NAME_AW(GetOpenFileName) #define GetOpenFileName WINELIB_NAME_AW(GetOpenFileName)
BOOL16 WINAPI GetSaveFileName16(SEGPTR ofn); BOOL16 WINAPI GetSaveFileName16(SEGPTR ofn);
BOOL WINAPI GetSaveFileNameA(LPOPENFILENAMEA ofn); BOOL WINAPI GetSaveFileNameA(LPOPENFILENAMEA ofn);
...@@ -636,11 +640,9 @@ LRESULT WINAPI FormatCharDlgProc16(HWND16,UINT16,WPARAM16,LPARAM); ...@@ -636,11 +640,9 @@ LRESULT WINAPI FormatCharDlgProc16(HWND16,UINT16,WPARAM16,LPARAM);
LRESULT WINAPI FormatCharDlgProcA(HWND,UINT,WPARAM,LPARAM); LRESULT WINAPI FormatCharDlgProcA(HWND,UINT,WPARAM,LPARAM);
LRESULT WINAPI FormatCharDlgProcW(HWND,UINT,WPARAM,LPARAM); LRESULT WINAPI FormatCharDlgProcW(HWND,UINT,WPARAM,LPARAM);
#define FormatCharDlgProc WINELIB_NAME_AW(FormatCharDlgProc) #define FormatCharDlgProc WINELIB_NAME_AW(FormatCharDlgProc)
INT16 WINAPI FontFamilyEnumProc16( SEGPTR logfont, SEGPTR metrics, UINT16 nFontType, LPARAM lParam);
INT16 WINAPI FontStyleEnumProc16( SEGPTR logfont, SEGPTR metrics, UINT16 nFontType, LPARAM lParam);
BOOL WINAPI COMMDLG_DllEntryPoint(DWORD Reason, HINSTANCE16 hInst, WORD ds, WORD HeapSize, DWORD res1, WORD res2); void COMDLG32_SetCommDlgExtendedError(DWORD err);
BOOL WINAPI COMDLG32_DllEntryPoint(HINSTANCE hInstance, DWORD Reason, LPVOID Reserved);
#include "poppack.h" #include "poppack.h"
......
...@@ -183,4 +183,34 @@ ...@@ -183,4 +183,34 @@
#define FORMATDLGORD31 1543 #define FORMATDLGORD31 1543
#define FORMATDLGORD30 1544 #define FORMATDLGORD30 1544
#define IDD_OPENDIALOG 101
#define IDD_SAVEDIALOG 201
#define IDS_ABOUTBOX 101
#define IDS_DOCUMENTFOLDERS 102
#define IDS_PERSONAL 103
#define IDS_FAVORITES 104
#define IDS_PATH 105
#define IDS_DESKTOP 106
#define IDB_TOOLBAR 107
#define IDS_FONTS 108
#define IDS_MYCOMPUTER 110
#define IDS_SYSTEMFOLDERS 112
#define IDS_LOCALHARDRIVES 113
#define IDS_FILENOTFOUND 114
#define IDS_VERIFYFILE 115
#define IDS_CREATEFILE 116
#define IDC_OPENREADONLY 410
#define IDC_FILETYPESTATIC 441
#define IDC_FILENAMESTATIC 442
#define IDC_LOOKINSTATIC 443
#define IDC_SHELLSTATIC 461
#define IDC_FILETYPE 470
#define IDC_LOOKIN 471
#define IDC_FILENAME 480
#define IDC_UPFOLDER 1009
#define IDC_NEWFOLDER 1010
#define IDC_LIST 1011
#define IDC_DETAILS 1014
#endif /* #ifdef __WINE_DLGS_H */ #endif /* #ifdef __WINE_DLGS_H */
...@@ -47,16 +47,16 @@ extern "C" { ...@@ -47,16 +47,16 @@ extern "C" {
/* FIXME: stricoll is not implemented but strcasecmp is probably close enough in most cases */ /* FIXME: stricoll is not implemented but strcasecmp is probably close enough in most cases */
#define _stricoll strcasecmp #define _stricoll strcasecmp
#define stricoll _stricoll #define stricoll _stricoll
#define strlwr _strlwr #define strlwr CRTDLL__strlwr
char *_strlwr(char *string); char *CRTDLL__strlwr(char *string);
#define strnset _strnset #define strnset _strnset
/* FIXME: _strnset is not implemented */ /* FIXME: _strnset is not implemented */
#define strrev _strrev #define strrev CRTDLL__strrev
char *_strrev(char *string); char *CRTDLL__strrev(char *string);
#define strset _strset #define strset _strset
/* FIXME: _strset is not implemented */ /* FIXME: _strset is not implemented */
#define strupr _strupr #define strupr CRTDLL__strupr
char *_strupr(char *string); char *CRTDLL__strupr(char *string);
#define ultoa _ultoa #define ultoa _ultoa
/* FIXME: _ultoa is not implemented */ /* FIXME: _ultoa is not implemented */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment