Author: pschweitzer
Date: Thu Dec 27 15:49:46 2007
New Revision: 31459
URL:
http://svn.reactos.org/svn/reactos?rev=31459&view=rev
Log:
- Definitively get rid of pidl work
- Now, previous path is just selected in browse window
Modified:
trunk/tools/RosBE/RosBE-Windows/Root/ChangeLog.txt
trunk/tools/RosBE/RosBE-Windows/Tools/config/options.c
trunk/tools/RosBE/RosBE-Windows/Tools/config/options.h
Modified: trunk/tools/RosBE/RosBE-Windows/Root/ChangeLog.txt
URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE/RosBE-Windows/Root/Cha…
==============================================================================
--- trunk/tools/RosBE/RosBE-Windows/Root/ChangeLog.txt (original)
+++ trunk/tools/RosBE/RosBE-Windows/Root/ChangeLog.txt Thu Dec 27 15:49:46 2007
@@ -3,9 +3,10 @@
- Updated RosBE Configuration Tool. (Pierre Schweitzer)
- Removed an used var (Pierre Schweitzer)
- Removed magic value use (Pierre Schweitzer)
- - Deactivated temporarily pidl work because of unwanted effects (Pierre Schweitzer)
- Fixed the a bug : user can now enter the path in browse dialog, and it will be used
(if correct) (Pierre Schweitzer)
- If there's a slash at the end of the entered path, it's removed (Pierre
Schweitzer)
+ - Definitively get rid of pidl work (Pierre Schweitzer)
+ - Now, previous path is just selected in browse window (Pierre Schweitzer)
- Added a "all" switch to clean.cmd to do both jobs, deleting Compiler Output
AND Logs in one process. (Daniel Reimer)
- Add a macro file for the MinGW prompt and add SCUT to this macro file (Colin Finck)
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 Thu Dec 27 15:49:46 2007
@@ -257,28 +257,42 @@
INT CALLBACK
BrowseProc(HWND Dlg, UINT Msg, WPARAM wParam, LPARAM lParam)
{
- if ((Msg == BFFM_VALIDATEFAILED) && (lParam != ID_MGWDIR))
- {
- WCHAR BoxMsg[256], BoxTitle[128];
- HWND hwndParent;
- INT PathLen;
- hwndParent = GetWindow(Dlg, GW_OWNER);
- LoadString(hInstance, MSG_WARNINGBOX, BoxTitle, 128);
- LoadString(hInstance, MSG_INVALIDDIR, BoxMsg, 256);
- if (MessageBox(Dlg, BoxMsg, BoxTitle, MB_ICONWARNING | MB_YESNO) == IDYES)
- {
- PathLen = wcslen((LPWSTR)wParam);
- if (wcscmp((LPWSTR)wParam+PathLen, L"\\"))
- wcsset((LPWSTR)wParam+(PathLen-1), '\0');
- if (CreateDirectory((LPWSTR)wParam, NULL) == 0)
- {
- LoadString(hInstance, MSG_DIREFAILED, BoxMsg, 256);
- MessageBox(Dlg, BoxMsg, NULL, MB_ICONERROR);
- }
- else
- {
- SetDlgItemText(hwndParent, lParam, (LPWSTR)wParam);
- }
+ HWND hwndParent;
+ hwndParent = GetWindow(Dlg, GW_OWNER);
+ switch (Msg)
+ {
+ case BFFM_INITIALIZED:
+ {
+ WCHAR ActualPath[MAX_PATH];
+ GetDlgItemText(hwndParent, lParam, ActualPath, MAX_PATH);
+ SendMessage(Dlg, BFFM_SETSELECTION, TRUE, (LPARAM)ActualPath);
+ break;
+ }
+ case BFFM_VALIDATEFAILED:
+ {
+ if (lParam != ID_MGWDIR)
+ {
+ WCHAR BoxMsg[256], BoxTitle[128];
+ INT PathLen;
+ LoadString(hInstance, MSG_WARNINGBOX, BoxTitle, 128);
+ LoadString(hInstance, MSG_INVALIDDIR, BoxMsg, 256);
+ if (MessageBox(Dlg, BoxMsg, BoxTitle, MB_ICONWARNING | MB_YESNO) ==
IDYES)
+ {
+ PathLen = wcslen((LPWSTR)wParam);
+ if (wcscmp((LPWSTR)wParam+PathLen, L"\\"))
+ wcsset((LPWSTR)wParam+(PathLen-1), '\0');
+ if (CreateDirectory((LPWSTR)wParam, NULL) == 0)
+ {
+ LoadString(hInstance, MSG_DIREFAILED, BoxMsg, 256);
+ MessageBox(Dlg, BoxMsg, NULL, MB_ICONERROR);
+ }
+ else
+ {
+ SetDlgItemText(hwndParent, lParam, (LPWSTR)wParam);
+ }
+ }
+ }
+ break;
}
}
return FALSE;
@@ -373,16 +387,9 @@
PathInfo.ulFlags = BIF_EDITBOX | BIF_VALIDATE;
PathInfo.lpfn = (BFFCALLBACK)BrowseProc;
PathInfo.lParam = ID_LOGDIR;
-#if 0
- SHGetSpecialFolderLocation(NULL, CSIDL_PROGRAM_FILES,
&pidl);
- PathInfo.pidlRoot = pidl;
-#endif
+ PathInfo.pidlRoot = NULL;
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)
@@ -396,19 +403,6 @@
IDText = MSG_FINDOUTDIR;
}
PathInfo.lParam = Control;
-#if 0
- hDLL = LoadLibrary(L"shell32.dll");
- if (hDLL)
- {
- ILCreateFromPathW =
(ILCREATEFROMPATHW)GetProcAddress(hDLL, "ILCreateFromPathW");
- if (ILCreateFromPathW)
- {
- GetDlgItemTextW(Dlg, Control, path, MAX_PATH);
- PathInfo.pidlRoot = ILCreateFromPathW(path);
- }
- 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 Thu Dec 27 15:49:46 2007
@@ -15,10 +15,6 @@
#include "resources.h"
#define MINGWVERSION L"\\4.1.3"
-
-#if 0
-typedef LPITEMIDLIST (CALLBACK* ILCREATEFROMPATHW)(LPCWSTR path);
-#endif
typedef struct _SETTINGS
{