gecko-dev/cck/driver/wizshell.cpp

67 строки
1.5 KiB
C++
Исходник Обычный вид История

1999-05-25 11:42:48 +04:00
#include "stdafx.h"
1999-10-23 03:42:02 +04:00
#include "globals.h"
1999-05-25 11:42:48 +04:00
#include "WizardMachine.h"
#include "fstream.h"
#include "direct.h"
extern char iniFilePath[MAX_SIZE];
extern char customizationPath[MAX_SIZE];
extern CWizardMachineApp theApp;
1999-10-25 09:14:12 +04:00
extern char currDirPath[MAX_SIZE];
1999-05-25 11:42:48 +04:00
//CString CDout="CD_output";
void CreateRshell (void)
{
1999-10-25 09:14:12 +04:00
CString root = GetGlobal("Root");
CString config = GetGlobal("CustomizationList");
CString destPath = root + "\\Configs\\" + config + "\\Rshell";
CWnd Mywnd;
1999-05-25 11:42:48 +04:00
1999-05-26 03:17:31 +04:00
// Mywnd.MessageBox(CString(iniFilePath),iniFilePath,MB_OK);
1999-05-25 11:42:48 +04:00
1999-05-26 03:17:31 +04:00
// Mywnd.MessageBox(CString(customizationPath),customizationPath,MB_OK);
1999-05-25 11:42:48 +04:00
ifstream part1("part1.ini");
ifstream part2("part2.ini");
1999-10-25 09:14:12 +04:00
_mkdir (destPath);
CString Rsh = destPath + "\\" +"rshell.ini";
1999-05-25 11:42:48 +04:00
// FILE* rshell = theApp.OpenAFile(CDdir +"rshell.ini", "w");
ofstream rshell(Rsh);
1999-10-23 03:42:02 +04:00
CString fvalue1=GetGlobal("ShellTitleText");
CString fvalue2=GetGlobal("ShellBgBitmap");
1999-05-25 11:42:48 +04:00
// char *fvalue3=GetGlobal("dialog_title_text");
1999-10-23 03:42:02 +04:00
CString fvalue4=GetGlobal("ShellInstallTextFile");
1999-05-25 11:42:48 +04:00
char jsprefname[200];
if(!part1) {
cout << "cannot open the file \n";
}
while (!part1.eof()) {
part1.getline(jsprefname,200);
// fprintf(globs, jsprefname);
// fprintf(globs, "\n");
rshell <<jsprefname<<"\n";
}
rshell <<"caption="<<fvalue1<<"\n";
rshell <<"bk_bitmap="<<fvalue2<<"\n";
rshell <<"button2_cmdline="<<fvalue4<<"\n";
// rshell <<"dialog_title_txt="<<fvalue3<<"\n";
if(!part2) {
cout << "cannot open the file \n";
}
while (!part2.eof()) {
part2.getline(jsprefname,200);
rshell <<jsprefname<<"\n";
}
rshell.close();
1999-10-23 03:42:02 +04:00
}