Author: dreimer
Date: Wed Oct 24 17:32:10 2007
New Revision: 29852
URL:
http://svn.reactos.org/svn/reactos?rev=29852&view=rev
Log:
/me == stupid. OK, next time I will initialize everything...
Modified:
trunk/tools/RosBE-Windows/Tools/config/options.c
trunk/tools/RosBE-Windows/Tools/config/resources.h
Modified: trunk/tools/RosBE-Windows/Tools/config/options.c
URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE-Windows/Tools/config/o…
==============================================================================
--- trunk/tools/RosBE-Windows/Tools/config/options.c (original)
+++ trunk/tools/RosBE-Windows/Tools/config/options.c Wed Oct 24 17:32:10 2007
@@ -47,8 +47,8 @@
WriteSettings(HWND hwnd)
{
int foreground, background;
- BOOL showtime, writelog, useccache, strip;
- WCHAR logdir[MAX_PATH], mingwpath[MAX_PATH], checkmgw[MAX_PATH], checklog[MAX_PATH];
+ BOOL showtime, writelog, useccache, strip, otherobj, otherout;
+ WCHAR logdir[MAX_PATH], objdir[MAX_PATH], outdir[MAX_PATH], mingwpath[MAX_PATH],
checkmgw[MAX_PATH], checklog[MAX_PATH];
WCHAR msgerror[256];
HANDLE hFile;
FILE *pFile;
@@ -57,10 +57,14 @@
writelog = (SendDlgItemMessage(hwnd, ID_SAVELOGS, BM_GETCHECK, 0, 0) ==
BST_CHECKED);
useccache = (SendDlgItemMessage(hwnd, ID_USECCACHE, BM_GETCHECK, 0, 0) ==
BST_CHECKED);
strip = (SendDlgItemMessage(hwnd, ID_STRIP, BM_GETCHECK, 0, 0) == BST_CHECKED);
+ otherobj = (SendDlgItemMessage(hwnd, ID_OTHEROBJ, BM_GETCHECK, 0, 0) ==
BST_CHECKED);
+ otherout = (SendDlgItemMessage(hwnd, ID_OTHEROUT, BM_GETCHECK, 0, 0) ==
BST_CHECKED);
foreground = (UINT)SendDlgItemMessage(hwnd, IDC_FONT, CB_GETCURSEL, 0, 0);
background = (UINT)SendDlgItemMessage(hwnd, IDC_BACK, CB_GETCURSEL, 0, 0);
GetDlgItemText(hwnd, ID_LOGDIR, logdir, MAX_PATH);
GetDlgItemText(hwnd, ID_MGWDIR, mingwpath, MAX_PATH);
+ GetDlgItemText(hwnd, ID_OBJDIR, objdir, MAX_PATH);
+ GetDlgItemText(hwnd, ID_OUTDIR, outdir, MAX_PATH);
if (writelog)
{
@@ -106,6 +110,8 @@
fprintf(pFile, "set _ROSBE_WRITELOG=%d\n", writelog);
fprintf(pFile, "set _ROSBE_LOGDIR=%S\n", logdir);
fprintf(pFile, "set _ROSBE_MINGWPATH=%S\n", mingwpath);
+ fprintf(pFile, "set _ROSBE_OBJPATH=%S\n", objdir);
+ fprintf(pFile, "set _ROSBE_OUTPATH=%S\n", outdir);
fclose(pFile);
return TRUE;
}
@@ -175,6 +181,8 @@
}
case ID_BROWSE:
case ID_BROWSEMGW:
+ case ID_BROWSEOBJ:
+ case ID_BROWSEOUT:
{
BROWSEINFO PathInfo;
LPITEMIDLIST pidl;
@@ -203,7 +211,42 @@
FreeLibrary(hDLL);
}
}
-
+ if (wParam == ID_BROWSEOBJ)
+ {
+ HINSTANCE hDLL;
+ ILCREATEFROMPATHW ILCreateFromPathW;
+ Control = ID_OBJDIR;
+ PathInfo.lpszTitle = L"Please choose the directory where
you want to save OBJ Files to:";
+ hDLL = LoadLibrary(L"shell32.dll");
+ if (hDLL)
+ {
+ ILCreateFromPathW =
(ILCREATEFROMPATHW)GetProcAddress(hDLL, "ILCreateFromPathW");
+ if (ILCreateFromPathW)
+ {
+ GetDlgItemText(Dlg, ID_OBJDIR, path, MAX_PATH);
+ PathInfo.pidlRoot = ILCreateFromPathW(path);
+ }
+ FreeLibrary(hDLL);
+ }
+ }
+ if (wParam == ID_BROWSEOUT)
+ {
+ HINSTANCE hDLL;
+ ILCREATEFROMPATHW ILCreateFromPathW;
+ Control = ID_OUTDIR;
+ PathInfo.lpszTitle = L"Please choose the directory where
you want to save OBJ Files to:";
+ hDLL = LoadLibrary(L"shell32.dll");
+ if (hDLL)
+ {
+ ILCreateFromPathW =
(ILCREATEFROMPATHW)GetProcAddress(hDLL, "ILCreateFromPathW");
+ if (ILCreateFromPathW)
+ {
+ GetDlgItemText(Dlg, ID_OUTDIR, path, MAX_PATH);
+ PathInfo.pidlRoot = ILCreateFromPathW(path);
+ }
+ FreeLibrary(hDLL);
+ }
+ }
pidl = SHBrowseForFolder(&PathInfo);
if (pidl)
{
@@ -228,6 +271,24 @@
EnableWindow(GetDlgItem(Dlg, ID_LOGDIR), WriteLogSet);
break;
}
+ case ID_OTHEROBJ:
+ {
+ BOOL WriteLogSet;
+ WriteLogSet = SendDlgItemMessage(Dlg, ID_OTHEROBJ, BM_GETCHECK,
0, 0) == BST_CHECKED;
+ EnableWindow(GetDlgItem(Dlg, ID_BROWSEOBJ), WriteLogSet);
+ EnableWindow(GetDlgItem(Dlg, ID_OBJDIR), WriteLogSet);
+ EnableWindow(GetDlgItem(Dlg, ID_OK), TRUE);
+ break;
+ }
+ case ID_OTHEROUT:
+ {
+ BOOL WriteLogSet;
+ WriteLogSet = SendDlgItemMessage(Dlg, ID_OTHEROUT, BM_GETCHECK,
0, 0) == BST_CHECKED;
+ EnableWindow(GetDlgItem(Dlg, ID_BROWSEOUT), WriteLogSet);
+ EnableWindow(GetDlgItem(Dlg, ID_OUTDIR), WriteLogSet);
+ EnableWindow(GetDlgItem(Dlg, ID_OK), TRUE);
+ break;
+ }
}
}
Modified: trunk/tools/RosBE-Windows/Tools/config/resources.h
URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE-Windows/Tools/config/r…
==============================================================================
--- trunk/tools/RosBE-Windows/Tools/config/resources.h (original)
+++ trunk/tools/RosBE-Windows/Tools/config/resources.h Wed Oct 24 17:32:10 2007
@@ -4,20 +4,20 @@
#define ID_OPTICON 0x03
#define ID_SAVELOGS 0x04
#define ID_SHOWBUILDTIME 0x05
-#define ID_LOGDIR 0x06
-#define ID_BROWSE 0x07
-#define ID_MGWDIR 0x08
-#define ID_BROWSEMGW 0x09
-#define ID_DIALOG 0x0a
-#define ID_EXAMPLE 0x0b
-#define ID_USECCACHE 0x0c
-#define ID_STRIP 0x0d
-#define ID_OBJDIR 0x0e
-#define ID_OUTDIR 0x0f
+#define ID_USECCACHE 0x06
+#define ID_STRIP 0x07
+#define ID_OTHEROBJ 0x08
+#define ID_OTHEROUT 0x09
+#define ID_LOGDIR 0x0a
+#define ID_MGWDIR 0x0b
+#define ID_OBJDIR 0x0c
+#define ID_OUTDIR 0x0d
+#define ID_BROWSE 0x0e
+#define ID_BROWSEMGW 0x0f
#define ID_BROWSEOBJ 0x10
#define ID_BROWSEOUT 0x11
-#define ID_OTHEROBJ 0x12
-#define ID_OTHEROUT 0x13
+#define ID_DIALOG 0x12
+#define ID_EXAMPLE 0x13
#define IDC_FONT 0x14
#define IDC_BACK 0x15