Effettuate alcune modifiche sul programma di gestione tabelle.
git-svn-id: svn://10.65.10.50/trunk@4333 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
c6c820e7dc
commit
4a5c6edfb2
@ -15,8 +15,6 @@ protected:
|
||||
virtual void init_insert_mode(TMask& m) ;
|
||||
virtual void init_query_mode (TMask&);
|
||||
virtual int rewrite(const TMask& m);
|
||||
virtual void print(void);
|
||||
static bool stampa_handler(TMask_field& f, KEY k);
|
||||
public:
|
||||
TBnp_table_app() {}
|
||||
virtual ~TBnp_table_app() {}
|
||||
@ -58,7 +56,7 @@ void TBnp_table_app::init_query_mode(TMask& m)
|
||||
m.field(F_CAB).check_type(CHECK_REQUIRED);
|
||||
m.hide(F_CODICEABI);
|
||||
m.hide(F_CODICECAB);
|
||||
m.field(F_CODICEABI).check_type(CHECK_NONE);
|
||||
//m.field(F_CODICEABI).check_type(CHECK_NONE);
|
||||
m.field(F_CODICECAB).check_type(CHECK_NONE);
|
||||
}
|
||||
|
||||
@ -66,8 +64,11 @@ bool TBnp_table_app::user_create()
|
||||
{
|
||||
Tab_application::user_create();
|
||||
const TString& name = get_tabname();
|
||||
TMask& mask = *get_mask();
|
||||
mask.set_handler(B_PRINT, stampa_handler);
|
||||
if (name.empty())
|
||||
{
|
||||
error_box("Specificare la tabella sulla linea di comando.");
|
||||
return FALSE;
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@ -81,22 +82,9 @@ int TBnp_table_app::rewrite(const TMask& m)
|
||||
return Tab_application::rewrite(m);
|
||||
}
|
||||
|
||||
void TBnp_table_app::print()
|
||||
{
|
||||
Tab_application::print();
|
||||
}
|
||||
|
||||
bool TBnp_table_app::stampa_handler(TMask_field& f, KEY k)
|
||||
{
|
||||
TMask &m = f.mask();
|
||||
if (k == K_SPACE)
|
||||
app().print();
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
int ef0700(int argc, char* argv[])
|
||||
{
|
||||
TBnp_table_app a ;
|
||||
a.run(argc, argv, "Gestione Tabella");
|
||||
a.run(argc, argv, "Gestione tabelle");
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user