[sword-cvs] sword/apps/windoze/CBuilder5/InstallMgr InstallManager.bpr,1.3,1.4 InstallManager.res,1.2,1.3 MainFrm.cpp,1.22,1.23 RemoteMntFrm.cpp,1.6,1.7

sword@www.crosswire.org sword@www.crosswire.org
Fri, 15 Aug 2003 01:52:17 -0700


Update of /usr/local/cvsroot/sword/apps/windoze/CBuilder5/InstallMgr
In directory www:/tmp/cvs-serv15374/apps/windoze/CBuilder5/InstallMgr

Modified Files:
	InstallManager.bpr InstallManager.res MainFrm.cpp 
	RemoteMntFrm.cpp 
Log Message:
no message

Index: InstallManager.bpr
===================================================================
RCS file: /usr/local/cvsroot/sword/apps/windoze/CBuilder5/InstallMgr/InstallManager.bpr,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- InstallManager.bpr	14 Aug 2003 00:57:38 -0000	1.3
+++ InstallManager.bpr	15 Aug 2003 08:52:15 -0000	1.4
@@ -80,7 +80,7 @@
 LegalTrademarks=
 OriginalFilename=
 ProductName=The SWORD Project
-ProductVersion=1.5.6rc2
+ProductVersion=1.5.6rc3
 Comments=Seek Jesus who exchanges temporary for eternal
 
 [HistoryLists\hlIncludePath]

Index: InstallManager.res
===================================================================
RCS file: /usr/local/cvsroot/sword/apps/windoze/CBuilder5/InstallMgr/InstallManager.res,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
Binary files /tmp/cvsTJKFiP and /tmp/cvsUJSNWY differ

Index: MainFrm.cpp
===================================================================
RCS file: /usr/local/cvsroot/sword/apps/windoze/CBuilder5/InstallMgr/MainFrm.cpp,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -d -r1.22 -r1.23
--- MainFrm.cpp	14 Aug 2003 00:57:38 -0000	1.22
+++ MainFrm.cpp	15 Aug 2003 08:52:15 -0000	1.23
@@ -73,22 +73,25 @@
 }
 	
 __fastcall TMainForm::TMainForm(TComponent* Owner)
-	: TForm(Owner)
-{
-     try {
+		: TForm(Owner) {
+	try {
 	    manager = new SWMgr();
-     }
-     catch (...) {
-           FileMgr::createPathAndFile("./mods.d/globals.conf");           
-           manager = new SWMgr();
-     }
+	}
+	catch (...) {
+		 FileMgr::createPathAndFile("./mods.d/globals.conf");           
+		 manager = new SWMgr();
+	}
+
+	if (FileMgr::existsFile("./InstallMgr.conf")) {
+		FileMgr::copyFile("./InstallMgr.conf", "installMgr/InstallMgr.conf");
+		FileMgr::removeFile("./InstallMgr.conf");
+	}
 	installMgr = new InstallMgrWin("./installMgr");
 	localMgr = 0;
 }
 
 
-__fastcall TMainForm::~TMainForm()
-{
+__fastcall TMainForm::~TMainForm() {
 	delete manager;
 	if (localMgr)
 		delete localMgr;
@@ -124,8 +127,7 @@
 }
 
 
-void TMainForm::addSource(InstallSourceTab *ist)
-{
+void TMainForm::addSource(InstallSourceTab *ist) {
 	TTabSheet *newtab = new TTabSheet(this);
 	TTreeView *newtree = new TTreeView(this);
 	TSpeedButton *newbutton = new TSpeedButton(this);
@@ -169,7 +171,6 @@
 		entry = installMgr->installConf->Sections["Sources"].find("LocalPath");
 	}
 	return entry->second.c_str();
-		
 }
 
 
@@ -179,8 +180,7 @@
 
 
 //---------------------------------------------------------------------------
-void __fastcall TMainForm::LocalPath1Click(TObject *Sender)
-{
+void __fastcall TMainForm::LocalPath1Click(TObject *Sender) {
 	AnsiString Dir = "C:";
 	WideString Root = getLocalDir();
 	SelectDirectory("Select Local Path", Root , Dir);
@@ -192,8 +192,7 @@
 }
 //---------------------------------------------------------------------------
 
-void TMainForm::fillInstallTree()
-{
+void TMainForm::fillInstallTree() {
 	ModMap::iterator mods;
 	TTreeNode *node;
 	SWBuf nodeName;
@@ -280,8 +279,8 @@
 		}
 
 		SWBuf misc1 = ((entry = sections->second.find("Category")) != sections->second.end()) ? (SWBuf)(*entry).second.c_str() : (SWBuf)"";
-          if (misc1.length() > 0)
-             secName = misc1;
+		if (misc1.length() > 0)
+		   secName = misc1;
 
 		entry = sections->second.find("Description");
 		if (entry != sections->second.end())
@@ -342,8 +341,7 @@
 }
 
 
-void __fastcall TMainForm::Button5Click(TObject *Sender)
-{
+void __fastcall TMainForm::Button5Click(TObject *Sender) {
 	TTreeView *tree;
 	for (int i = 0; i < PageControl1->ActivePage->ControlCount; i++) {
 		if (PageControl1->ActivePage->Controls[i]->ClassNameIs("TTreeView")) {
@@ -363,14 +361,12 @@
 }
 //---------------------------------------------------------------------------
 
-void __fastcall TMainForm::localTreeDblClick(TObject *Sender)
-{
+void __fastcall TMainForm::localTreeDblClick(TObject *Sender) {
 	Button5Click(Sender);
 }
 //---------------------------------------------------------------------------
 
-int TMainForm::selectAll(TTreeView *tree, bool sel)
-{
+int TMainForm::selectAll(TTreeView *tree, bool sel) {
 	TTreeNode *node;
 	TTreeNode *node2;
 	int retCount = 0;
@@ -395,8 +391,8 @@
 }
 
 
-void __fastcall TMainForm::Button6Click(TObject *Sender)	// SELECT ALL
-{
+// SELECT ALL
+void __fastcall TMainForm::Button6Click(TObject *Sender) {
 	TTreeView *tree;
 	for (int i = 0; i < PageControl1->ActivePage->ControlCount; i++) {
 		if (PageControl1->ActivePage->Controls[i]->ClassNameIs("TTreeView")) {
@@ -410,16 +406,13 @@
 }
 //---------------------------------------------------------------------------
 
-void __fastcall TMainForm::Image1Click(TObject *Sender)
-{
+void __fastcall TMainForm::Image1Click(TObject *Sender) {
 	ShellExecute(this->Handle, "open", "http://www.crosswire.org", NULL, NULL, SW_SHOWNORMAL);
-
 }
 //---------------------------------------------------------------------------
 
 
-void	TMainForm::fillAllSourceTrees()
-{
+void	TMainForm::fillAllSourceTrees() {
 	fillSourceTree(localTree);
 	for (int i = 1; i < PageControl1->PageCount; i++) {
 		InstallSourceTab *ist = (InstallSourceTab *) MainForm->PageControl1->Pages[i]->Controls[0];
@@ -428,8 +421,8 @@
 }
 
 
-void __fastcall TMainForm::Button4Click(TObject *Sender)	// REMOVE MODULE
-{
+// REMOVE MODULE
+void __fastcall TMainForm::Button4Click(TObject *Sender) {
 	TTreeNode *node = installTree->Selected;
 	if (node) {
 		if (node->Parent) {
@@ -443,8 +436,8 @@
 }
 //---------------------------------------------------------------------------
 
-void __fastcall TMainForm::Button2Click(TObject *Sender)	// INSTALL
-{
+// INSTALL
+void __fastcall TMainForm::Button2Click(TObject *Sender) {
 	TTreeNode *node;
 	int count = 0;
 	int abort = 0;
@@ -512,8 +505,7 @@
 
 
 
-void __fastcall TMainForm::SpeedButton1Click(TObject *Sender)
-{
+void __fastcall TMainForm::SpeedButton1Click(TObject *Sender) {
 	InfoForm->Caption = "W A R N I N G";
 	InfoForm->info = "\\qc {\\b \\fs20 -=+* WARNING *+=- -=+* WARNING *+=-}\\par\\par\\pard ";
 	InfoForm->info += "Although Install Manager provides a convenient way for installing and upgrading SWORD components, it also uses a systematic method for accessing sites which gives packet sniffers a target to lock into for singling out users. \\par\\par ";
@@ -601,8 +593,7 @@
 }
 //---------------------------------------------------------------------------
 
-void __fastcall TMainForm::Exit1Click(TObject *Sender)
-{
+void __fastcall TMainForm::Exit1Click(TObject *Sender) {
 	Close();	
 }
 //---------------------------------------------------------------------------
@@ -638,8 +629,9 @@
 	UninstallForm->Hide();
 	return;
 }
-void __fastcall TMainForm::FormShow(TObject *Sender)
-{
+
+
+void __fastcall TMainForm::FormShow(TObject *Sender) {
 	for (int i=0;i<=ParamCount();i++) {
 		if (LowerCase(ParamStr(i)) == "-uninstall") {
 			deleteAllModules();
@@ -666,8 +658,7 @@
 }
 //---------------------------------------------------------------------------
 
-void __fastcall TMainForm::Contents1Click(TObject *Sender)
-{
+void __fastcall TMainForm::Contents1Click(TObject *Sender) {
 	SWConfig optionsconf("options.conf");
 	SWBuf helpDir;
 	ConfigEntMap::iterator it = optionsconf.Sections["Help"].find("Directory");

Index: RemoteMntFrm.cpp
===================================================================
RCS file: /usr/local/cvsroot/sword/apps/windoze/CBuilder5/InstallMgr/RemoteMntFrm.cpp,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- RemoteMntFrm.cpp	27 Jun 2003 01:41:06 -0000	1.6
+++ RemoteMntFrm.cpp	15 Aug 2003 08:52:15 -0000	1.7
@@ -17,7 +17,7 @@
 class TRemoteSource : public TObject {
 public:
 	InstallSource is;
-	TRemoteSource(const char *confEnt) : is(confEnt, "FTP") {
+	TRemoteSource(const char *confEnt) : is("FTP", confEnt) {
 	}
 };
 
@@ -31,7 +31,7 @@
 void __fastcall TRemoteMntForm::FormShow(TObject *Sender)
 {
 	ConfigEntMap::iterator loop, end;
-	config = new SWConfig("./InstallMgr.conf");	
+	config = new SWConfig("./installMgr/InstallMgr.conf");	
 	ListBox1->Clear();
 	loop = config->Sections["Sources"].lower_bound("FTPSource");
 	end = config->Sections["Sources"].upper_bound("FTPSource");