--- trunk/reactos/subsys/system/winefile/winefile.c 2005-06-09 20:40:44 UTC (rev 15850)
+++ trunk/reactos/subsys/system/winefile/winefile.c 2005-06-10 20:41:26 UTC (rev 15851)
@@ -154,10 +154,7 @@
} ChildWnd;
-extern void WineLicense(HWND hwnd);
-extern void WineWarranty(HWND hwnd);
-
#ifdef __WINE__
/* functions in unixcalls.c */
@@ -211,9 +208,9 @@
static void get_path(Entry* dir, PTSTR path);
static void format_date(const FILETIME* ft, TCHAR* buffer, int visible_cols);
-LRESULT CALLBACK FrameWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-LRESULT CALLBACK ChildWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
-LRESULT CALLBACK TreeWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
+static LRESULT CALLBACK FrameWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
+static LRESULT CALLBACK ChildWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
+static LRESULT CALLBACK TreeWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam);
/* globals */
@@ -723,7 +720,7 @@
}
-HRESULT name_from_pidl(IShellFolder* folder, LPITEMIDLIST pidl, LPTSTR buffer, int len, SHGDNF flags)
+static HRESULT name_from_pidl(IShellFolder* folder, LPITEMIDLIST pidl, LPTSTR buffer, int len, SHGDNF flags)
{
STRRET str;
@@ -739,7 +736,7 @@
}
-HRESULT path_from_pidlA(IShellFolder* folder, LPITEMIDLIST pidl, LPSTR buffer, int len)
+static HRESULT path_from_pidlA(IShellFolder* folder, LPITEMIDLIST pidl, LPSTR buffer, int len)
{
STRRET str;
@@ -755,7 +752,7 @@
return hr;
}
-HRESULT path_from_pidlW(IShellFolder* folder, LPITEMIDLIST pidl, LPWSTR buffer, int len)
+static HRESULT path_from_pidlW(IShellFolder* folder, LPITEMIDLIST pidl, LPWSTR buffer, int len)
{
STRRET str;
@@ -827,7 +824,7 @@
}
-HICON extract_icon(IShellFolder* folder, LPCITEMIDLIST pidl)
+static HICON extract_icon(IShellFolder* folder, LPCITEMIDLIST pidl)
{
IExtractIcon* pExtract;
@@ -1606,7 +1603,7 @@
static HHOOK hcbthook;
static ChildWnd* newchild = NULL;
-LRESULT CALLBACK CBTProc(int code, WPARAM wparam, LPARAM lparam)
+static LRESULT CALLBACK CBTProc(int code, WPARAM wparam, LPARAM lparam)
{
if (code==HCBT_CREATEWND && newchild) {
ChildWnd* child = newchild;
@@ -1971,7 +1968,7 @@
FALSE
};
-void frame_get_clientspace(HWND hwnd, PRECT prect)
+static void frame_get_clientspace(HWND hwnd, PRECT prect)
{
RECT rt;
@@ -2072,7 +2069,7 @@
resize_frame_client(hwnd);
}
-BOOL activate_drive_window(LPCTSTR path)
+static BOOL activate_drive_window(LPCTSTR path)
{
TCHAR drv1[_MAX_DRIVE], drv2[_MAX_DRIVE];
HWND child_wnd;
@@ -2100,7 +2097,7 @@
return FALSE;
}
-BOOL activate_fs_window(LPCTSTR filesys)
+static BOOL activate_fs_window(LPCTSTR filesys)
{
HWND child_wnd;
@@ -2123,7 +2120,7 @@
return FALSE;
}
-LRESULT CALLBACK FrameWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
+static LRESULT CALLBACK FrameWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
{
TCHAR b1[BUFFER_LEN], b2[BUFFER_LEN];
@@ -2821,7 +2818,7 @@
_stprintf(buffer, sLongNumFmt, bytes);
}
-static void set_space_status()
+static void set_space_status(void)
{
ULARGE_INTEGER ulFreeBytesToCaller, ulTotalBytes, ulFreeBytes;
TCHAR fmt[64], b1[64], b2[64], buffer[BUFFER_LEN];
@@ -3743,7 +3740,7 @@
}
-static void create_drive_bar()
+static void create_drive_bar(void)
{
TBBUTTON drivebarBtn = {0, 0, TBSTATE_ENABLED, BTNS_BUTTON, {0, 0}, 0, 0};
#ifndef _NO_EXTENSIONS
@@ -3809,7 +3806,7 @@
}
}
-static void refresh_drives()
+static void refresh_drives(void)
{
RECT rect;
@@ -3826,7 +3823,7 @@
}
-BOOL launch_file(HWND hwnd, LPCTSTR cmd, UINT nCmdShow)
+static BOOL launch_file(HWND hwnd, LPCTSTR cmd, UINT nCmdShow)
{
HINSTANCE hinst = ShellExecute(hwnd, NULL/*operation*/, cmd, NULL/*parameters*/, NULL/*dir*/, nCmdShow);
@@ -3839,7 +3836,7 @@
}
#ifdef UNICODE
-BOOL launch_fileA(HWND hwnd, LPSTR cmd, UINT nCmdShow)
+static BOOL launch_fileA(HWND hwnd, LPSTR cmd, UINT nCmdShow)
{
HINSTANCE hinst = ShellExecuteA(hwnd, NULL/*operation*/, cmd, NULL/*parameters*/, NULL/*dir*/, nCmdShow);
@@ -3853,7 +3850,7 @@
#endif
-BOOL launch_entry(Entry* entry, HWND hwnd, UINT nCmdShow)
+static BOOL launch_entry(Entry* entry, HWND hwnd, UINT nCmdShow)
{
TCHAR cmd[MAX_PATH];
@@ -4072,7 +4069,7 @@
#endif
}
-IContextMenu* CtxMenu_query_interfaces(IContextMenu* pcm1)
+static IContextMenu* CtxMenu_query_interfaces(IContextMenu* pcm1)
{
IContextMenu* pcm = NULL;
@@ -4158,7 +4155,7 @@
}
-LRESULT CALLBACK ChildWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
+static LRESULT CALLBACK ChildWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
{
ChildWnd* child = (ChildWnd*) GetWindowLong(hwnd, GWL_USERDATA);
ASSERT(child);
@@ -4542,7 +4539,7 @@
}
-LRESULT CALLBACK TreeWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
+static LRESULT CALLBACK TreeWndProc(HWND hwnd, UINT nmsg, WPARAM wparam, LPARAM lparam)
{
ChildWnd* child = (ChildWnd*) GetWindowLong(GetParent(hwnd), GWL_USERDATA);
Pane* pane = (Pane*) GetWindowLong(hwnd, GWL_USERDATA);
@@ -4670,7 +4667,7 @@
}
-void show_frame(HWND hwndParent, int cmdshow)
+static void show_frame(HWND hwndParent, int cmdshow)
{
const static TCHAR sMDICLIENT[] = {'M','D','I','C','L','I','E','N','T','\0'};
@@ -4768,7 +4765,7 @@
UpdateWindow(Globals.hMainWnd);
}
-void ExitInstance()
+static void ExitInstance(void)
{
#ifdef _SHELL_FOLDERS
(*Globals.iDesktop->lpVtbl->Release)(Globals.iDesktop);
@@ -4779,6 +4776,7 @@
ImageList_Destroy(Globals.himl);
}
+#ifdef _NO_EXTENSIONS
/* search for already running win[e]files */
@@ -4799,7 +4797,7 @@
}
/* search for window of given class name to allow only one running instance */
-int find_window_class(LPCTSTR classname)
+static int find_window_class(LPCTSTR classname)
{
EnumWindows(EnumWndProc, (LPARAM)classname);
@@ -4809,8 +4807,9 @@
return 0;
}
+#endif
-int winefile_main(HINSTANCE hinstance, HWND hwndParent, int cmdshow)
+static int winefile_main(HINSTANCE hinstance, HWND hwndParent, int cmdshow)
{
MSG msg;