Author: pschweitzer
Date: Mon Dec 24 21:31:47 2007
New Revision: 31422
URL:
http://svn.reactos.org/svn/reactos?rev=31422&view=rev
Log:
- Removed magic value use
- Deactivated temporarily pidl work because of unwanted effects
- Fixed the a bug : user can now enter the path in browse dialog, and it will be used (if
correct)
Modified:
trunk/tools/RosBE/RosBE-Windows/Tools/config/options.c
trunk/tools/RosBE/RosBE-Windows/Tools/config/options.h
Modified: trunk/tools/RosBE/RosBE-Windows/Tools/config/options.c
URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE/RosBE-Windows/Tools/co…
==============================================================================
--- trunk/tools/RosBE/RosBE-Windows/Tools/config/options.c (original)
+++ trunk/tools/RosBE/RosBE-Windows/Tools/config/options.c Mon Dec 24 21:31:47 2007
@@ -36,7 +36,7 @@
GetDlgItemTextW(hwnd, ID_OUTDIR, outdir, MAX_PATH);
if (writelog && (logdir[0] != 0))
- if (GetFileAttributes(logdir) == 0xFFFFFFFF)
+ if (0 > (LONG)GetFileAttributes(logdir))
if (CreateDirectoryW(logdir, NULL) == 0)
{
LoadString(hInstance, MSG_DIREFAILED, msgerror, 256);
@@ -252,6 +252,12 @@
return FALSE;
}
return TRUE;
+}
+
+INT CALLBACK
+BrowseProc(HWND Dlg, UINT Msg, WPARAM wParam, LPARAM lParam)
+{
+ return FALSE;
}
INT_PTR CALLBACK
@@ -340,13 +346,18 @@
{
ZeroMemory(&PathInfo, sizeof(BROWSEINFO));
PathInfo.hwndOwner = Dlg;
- PathInfo.ulFlags = BIF_EDITBOX;
+ PathInfo.ulFlags = BIF_EDITBOX | BIF_VALIDATE;
+ PathInfo.lpfn = (BFFCALLBACK)BrowseProc;
+#if 0
SHGetSpecialFolderLocation(NULL, CSIDL_PROGRAM_FILES,
&pidl);
PathInfo.pidlRoot = pidl;
+#endif
if ((wParam == ID_BROWSEMGW) || (wParam == ID_BROWSEOBJ) ||
(wParam == ID_BROWSEOUT))
{
+#if 0
HINSTANCE hDLL;
ILCREATEFROMPATHW ILCreateFromPathW;
+#endif
Control = ID_MGWDIR;
IDText = MSG_FINDMGWDIR;
if (wParam == ID_BROWSEOBJ)
@@ -359,6 +370,7 @@
Control = ID_OUTDIR;
IDText = MSG_FINDOUTDIR;
}
+#if 0
hDLL = LoadLibrary(L"shell32.dll");
if (hDLL)
{
@@ -370,6 +382,7 @@
}
FreeLibrary(hDLL);
}
+#endif
}
LoadString(hInstance, IDText, Text, 512);
PathInfo.lpszTitle = Text;
Modified: trunk/tools/RosBE/RosBE-Windows/Tools/config/options.h
URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE/RosBE-Windows/Tools/co…
==============================================================================
--- trunk/tools/RosBE/RosBE-Windows/Tools/config/options.h (original)
+++ trunk/tools/RosBE/RosBE-Windows/Tools/config/options.h Mon Dec 24 21:31:47 2007
@@ -16,7 +16,9 @@
#define MINGWVERSION L"\\4.1.3"
+#if 0
typedef LPITEMIDLIST (CALLBACK* ILCREATEFROMPATHW)(LPCWSTR path);
+#endif
typedef struct _SETTINGS
{