COrretto riposizionamento browse e set descrizione quando si cambia

la lingua profilo


git-svn-id: svn://10.65.10.50/trunk@2510 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
villa 1996-01-29 09:07:31 +00:00
parent ab9b315b68
commit 6837247e67
2 changed files with 18 additions and 0 deletions

View File

@ -6,11 +6,27 @@
#include <comuni.h>
bool TEC_mask::lingua_handler(TMask_field& f, KEY k)
{
if (k == K_TAB && f.focusdirty())
{
TCursor& cur = *(((TEdit_field&)(f.mask().field(F_CODPROF))).browse()->cursor());
// whew
TString16 lin = f.get();
if (lin != cur.curr().get("CODPROF").mid(4))
f.mask().field(F_CODPROF).check(RUNNING_CHECK);
}
return TRUE;
}
TEC_mask::TEC_mask(const char* name) : TSelection_mask(name), _ditta(LF_NDITTE)
{
_ditta.add(LF_ANAG, "TIPOA==TIPOA|CODANAGR==CODANAGR");
_ditta.add(LF_COMUNI, "COM==COMRF(COMRES)", 1, LF_ANAG, 101);
_ditta.add(LF_COMUNI, "COM==COMRES", 1, LF_ANAG, 102);
set_handler(F_LINPROF, lingua_handler);
}
TEC_mask::~TEC_mask()

View File

@ -13,6 +13,8 @@ protected: // TMask
virtual void on_firm_change();
virtual void start_run();
static bool lingua_handler(TMask_field& f, KEY k);
public:
const char* get_prof_base() const;
const TString& get_prof_code() const;