Correto errore MI0604

git-svn-id: svn://10.65.10.50/trunk@1188 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
alex 1995-03-29 15:17:00 +00:00
parent f51135451c
commit 2267ea7e54

View File

@ -91,37 +91,37 @@ void TConfig_application::do_config(int m)
int k = m.run(); int k = m.run();
if (!postprocess_config(m,cnf)) if (!postprocess_config(m,cnf))
break;
bool tosave = k == K_ENTER || k == K_SAVE;
if (k == K_ENTER || k == K_QUIT)
{ {
// aggiusta campi bool tosave = k == K_ENTER || k == K_SAVE;
for (i = 0; i < m.fields(); i++)
if (k == K_ENTER || k == K_QUIT)
{ {
TMask_field& f = m.fld(i); // aggiusta campi
if (f.dirty()) for (i = 0; i < m.fields(); i++)
{ {
const TFieldref* fref = f.field(); TMask_field& f = m.fld(i);
if (fref != NULL) if (f.dirty())
{ {
const char* fname = fref->name(); const TFieldref* fref = f.field();
const char* value = f.get(); if (fref != NULL)
const char* oldvl = cnf.get(fname); {
const char* fname = fref->name();
if (!tosave) const char* value = f.get();
tosave = yesno_box("Modifiche non registrate. Salvare?"); const char* oldvl = cnf.get(fname);
if (!tosave) break; if (!tosave)
tosave = yesno_box("Modifiche non registrate. Salvare?");
if (postprocess_config_changed(par,fname, oldvl,value))
cnf.set(fname, value, NULL, TRUE); if (!tosave) break;
if (postprocess_config_changed(par,fname, oldvl,value))
cnf.set(fname, value, NULL, TRUE);
}
} }
} }
} }
} else break;
else break; }
if (k == K_QUIT) if (k == K_QUIT)
break comunque; break comunque;
} }