Patch level :4.0 nopatch
Files correlati : Ricompilazione Demo : [ ] Commento :setup in corso d'opera git-svn-id: svn://10.65.10.50/trunk@15581 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
9b75e411ee
commit
d681294c31
@ -234,8 +234,8 @@ public:
|
|||||||
};
|
};
|
||||||
|
|
||||||
CampoIniFile::CampoIniFile(const wxString strIniPath, const wxString strParagraph)
|
CampoIniFile::CampoIniFile(const wxString strIniPath, const wxString strParagraph)
|
||||||
: wxFileConfig (wxEmptyString, wxEmptyString, wxEmptyString, strIniPath,
|
: wxFileConfig (wxEmptyString, wxEmptyString, strIniPath, wxEmptyString,
|
||||||
wxCONFIG_USE_GLOBAL_FILE|wxCONFIG_USE_NO_ESCAPE_CHARACTERS)
|
wxCONFIG_USE_LOCAL_FILE|wxCONFIG_USE_NO_ESCAPE_CHARACTERS)
|
||||||
{
|
{
|
||||||
if (!strParagraph.IsEmpty())
|
if (!strParagraph.IsEmpty())
|
||||||
SetPath(strParagraph);
|
SetPath(strParagraph);
|
||||||
@ -2190,7 +2190,7 @@ void CampoSetup::OnTimer(wxTimerEvent& WXUNUSED(e))
|
|||||||
const unsigned int uInstallationType = pWizard->GetInstallationType();
|
const unsigned int uInstallationType = pWizard->GetInstallationType();
|
||||||
const bool bNewInstallation = uInstallationType < 3;
|
const bool bNewInstallation = uInstallationType < 3;
|
||||||
//installazione servers?
|
//installazione servers?
|
||||||
const bool bInstallLurch = uInstallationType == 1 && (pWizard->GetInstUseAuth() | pWizard->GetInstUseDict());
|
const bool bInstallLurch = uInstallationType == 1 && (pWizard->GetInstUseAuth() || pWizard->GetInstUseDict());
|
||||||
//cartelle selezionate dall'utente
|
//cartelle selezionate dall'utente
|
||||||
const wxString& strPrgLocPath = pWizard->GetPrgLocPath();
|
const wxString& strPrgLocPath = pWizard->GetPrgLocPath();
|
||||||
const wxString& strDataPath = pWizard->GetDataPath();
|
const wxString& strDataPath = pWizard->GetDataPath();
|
||||||
@ -2218,14 +2218,7 @@ void CampoSetup::OnTimer(wxTimerEvent& WXUNUSED(e))
|
|||||||
wxString strFileCurr;
|
wxString strFileCurr;
|
||||||
const size_t nPathLenght = strSourcePath.GetPath().Len();
|
const size_t nPathLenght = strSourcePath.GetPath().Len();
|
||||||
for (size_t i = 0; i < uFilesToCopy; i++)
|
for (size_t i = 0; i < uFilesToCopy; i++)
|
||||||
{
|
{
|
||||||
/* che fare con i servers? copiare la directory comunque o saltarli?
|
|
||||||
if (asFilesList[i].Lower().Find("\\servers\\") > 0 && bInstallLurch)
|
|
||||||
{
|
|
||||||
strFileCurr = strPrgLocPath;
|
|
||||||
strFileCurr += asFilesList[i].Mid(nPathLenght);
|
|
||||||
}
|
|
||||||
else*/
|
|
||||||
//files dei dati standard! solo in caso di nuova installazione!!
|
//files dei dati standard! solo in caso di nuova installazione!!
|
||||||
if (asFilesList[i].Lower().Find("\\dati\\") > 0)
|
if (asFilesList[i].Lower().Find("\\dati\\") > 0)
|
||||||
{
|
{
|
||||||
@ -2235,12 +2228,24 @@ void CampoSetup::OnTimer(wxTimerEvent& WXUNUSED(e))
|
|||||||
strFileCurr += asFilesList[i].Mid(nPathLenght + 5);
|
strFileCurr += asFilesList[i].Mid(nPathLenght + 5);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else //files dei programmi
|
else
|
||||||
{
|
{
|
||||||
strFileCurr = strPrgLocPath;
|
//che fare con i servers? copiare la directory..potrebbe servire
|
||||||
strFileCurr += asFilesList[i].Mid(nPathLenght);
|
if (asFilesList[i].Lower().Find("\\servers\\") > 0)
|
||||||
|
{
|
||||||
|
if (bInstallLurch)
|
||||||
|
{
|
||||||
|
strFileCurr = strPrgLocPath;
|
||||||
|
strFileCurr += "\\servers";
|
||||||
|
strFileCurr += asFilesList[i].Mid(nPathLenght + 8);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else //files dei programmi
|
||||||
|
{
|
||||||
|
strFileCurr = strPrgLocPath;
|
||||||
|
strFileCurr += asFilesList[i].Mid(nPathLenght);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//copia i files nella cartella di destinazione (programmi,dati,cazzi e mazzi);se il nome del file..
|
//copia i files nella cartella di destinazione (programmi,dati,cazzi e mazzi);se il nome del file..
|
||||||
//..di destinazione e' vuoto significa che non lo deve copiare!! (es. dati in aggiornamento)
|
//..di destinazione e' vuoto significa che non lo deve copiare!! (es. dati in aggiornamento)
|
||||||
if (!strFileCurr.IsEmpty())
|
if (!strFileCurr.IsEmpty())
|
||||||
@ -2277,22 +2282,24 @@ void CampoSetup::OnTimer(wxTimerEvent& WXUNUSED(e))
|
|||||||
//adesso deve compilare il campo.ini se nuova installazione..
|
//adesso deve compilare il campo.ini se nuova installazione..
|
||||||
if (bNewInstallation)
|
if (bNewInstallation)
|
||||||
{
|
{
|
||||||
//paragrafo [Main]
|
{ //parentesi necessaria per la scrittura immediata (non cancellare! serve per debug)
|
||||||
CampoIniFile CampoIniMain(strPrgLocPath + "/campo.ini", "Main");
|
//paragrafo [Main]
|
||||||
const unsigned int uDongleType = pWizard->GetDongleType();
|
CampoIniFile CampoIniMain(strPrgLocPath + "/campo.ini", "Main");
|
||||||
CampoIniMain.Set("Dongle", uDongleType);
|
const unsigned int uDongleType = pWizard->GetDongleType();
|
||||||
CampoIniMain.Set("Study", strDataPath);
|
CampoIniMain.Set("Donglehw", uDongleType);
|
||||||
CampoIniMain.Set("Firm", "com");
|
CampoIniMain.Set("Study", strDataPath);
|
||||||
//client o non client?
|
CampoIniMain.Set("Firm", "com");
|
||||||
if (uInstallationType == 2) //client
|
//client o non client?
|
||||||
{
|
if (uInstallationType == 2) //client
|
||||||
CampoIniMain.Set("TestDatabase", "N");
|
{
|
||||||
CampoIniMain.Set("TestPrograms", "X");
|
CampoIniMain.Set("TestDatabase", "N");
|
||||||
}
|
CampoIniMain.Set("TestPrograms", "X");
|
||||||
else //altri (standard,server)
|
}
|
||||||
{
|
else //altri (standard,server)
|
||||||
CampoIniMain.Set("TestDatabase", "X");
|
{
|
||||||
CampoIniMain.Set("TestPrograms", "N");
|
CampoIniMain.Set("TestDatabase", "X");
|
||||||
|
CampoIniMain.Set("TestPrograms", "N");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
//paragrafo [Server]
|
//paragrafo [Server]
|
||||||
if (bInstallLurch)
|
if (bInstallLurch)
|
||||||
@ -2305,18 +2312,20 @@ void CampoSetup::OnTimer(wxTimerEvent& WXUNUSED(e))
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//..e modificare comunque l'install.ini aggiornando eventualmente l'origine dei programmi
|
//..e modificare comunque l'install.ini aggiornando eventualmente l'origine dei programmi
|
||||||
CampoIniFile CampoInstall(strPrgLocPath + "/install.ini", "Main");
|
//parentesi necessaria per la scrittura immediata (non cancellare! serve per debug)
|
||||||
if (uInstallationType == 2) //client: directory origine sul server
|
|
||||||
CampoInstall.Set("DiskPath", pWizard->GetPrgNetPath());
|
|
||||||
else //e' il path assoluto dell'install.ini che sta in 'program' (es. D:\program)
|
|
||||||
{
|
{
|
||||||
wxFileName strSourcePath(wxGetCwd());
|
CampoIniFile CampoInstall(strPrgLocPath + "/install.ini", "Main");
|
||||||
strSourcePath.AppendDir("program");
|
if (uInstallationType == 2) //client: directory origine sul server
|
||||||
strSourcePath.MakeAbsolute();
|
CampoInstall.Set("DiskPath", pWizard->GetPrgNetPath());
|
||||||
const wxString strSrc = strSourcePath.GetPath();
|
else //e' il path assoluto dell'install.ini che sta in 'program' (es. D:\program)
|
||||||
CampoInstall.Set("DiskPath", strSrc);
|
{
|
||||||
|
wxFileName strSourcePath(wxGetCwd());
|
||||||
|
strSourcePath.AppendDir("program");
|
||||||
|
strSourcePath.MakeAbsolute();
|
||||||
|
const wxString strSrc = strSourcePath.GetPath();
|
||||||
|
CampoInstall.Set("DiskPath", strSrc);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//solo se sta installando campo in postazione server e deve installare un gestore di servizi..
|
//solo se sta installando campo in postazione server e deve installare un gestore di servizi..
|
||||||
//..avvia la procedura della creazione dell'autostart(un casino)
|
//..avvia la procedura della creazione dell'autostart(un casino)
|
||||||
if (bInstallLurch)
|
if (bInstallLurch)
|
||||||
@ -2344,9 +2353,6 @@ void CampoSetup::OnTimer(wxTimerEvent& WXUNUSED(e))
|
|||||||
|
|
||||||
// 4) lanciare ba1.exe -6 in uscita (non va qui! e' solo per ricordarsi di farlo!)
|
// 4) lanciare ba1.exe -6 in uscita (non va qui! e' solo per ricordarsi di farlo!)
|
||||||
|
|
||||||
//questo e' un esempio di associazione automatica di estensione file
|
|
||||||
//if (pWizard->GetBool(bAssocExtension))
|
|
||||||
// AssociateExtension(strExe, wxT(".caz"));
|
|
||||||
}
|
}
|
||||||
pWizard->Destroy();
|
pWizard->Destroy();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user