234118fa3b
Files correlati : Ricompilazione Demo : [ ] Commento : git-svn-id: svn://10.65.10.50/branches/R_10_00@20979 c028cbd2-c16b-5b4b-a496-9718f37d4682
98 lines
2.0 KiB
C++
Executable File
98 lines
2.0 KiB
C++
Executable File
#include <automask.h>
|
|
#include <confapp.h>
|
|
|
|
#include "ha0200a.h"
|
|
|
|
///////////////////////////////////////////////////
|
|
// Maschera
|
|
///////////////////////////////////////////////////
|
|
class TConf_Hardy_mask : public TAutomask
|
|
{
|
|
protected:
|
|
virtual bool on_field_event(TOperable_field& o, TField_event e, long jolly);
|
|
|
|
public:
|
|
void config_loader(TSheet_field& sf, const char* paragrafo);
|
|
void config_setter(TSheet_field& sf, const char* paragrafo);
|
|
TConf_Hardy_mask(const TFilename& f);
|
|
|
|
virtual ~TConf_Hardy_mask(){};
|
|
};
|
|
|
|
bool TConf_Hardy_mask::on_field_event(TOperable_field& o, TField_event e, long jolly)
|
|
{
|
|
/*switch (o.dlg())
|
|
{
|
|
default:
|
|
break;
|
|
}*/
|
|
return true;
|
|
}
|
|
|
|
TConf_Hardy_mask::TConf_Hardy_mask(const TFilename& f) : TAutomask (f)
|
|
{
|
|
}
|
|
|
|
///////////////////////////////////////////////////
|
|
// Applicazione
|
|
///////////////////////////////////////////////////
|
|
class TConf_Hardy : public TConfig_application
|
|
{
|
|
TMask* _ch;
|
|
|
|
protected:
|
|
virtual TMask* create_mask(const TFilename& f);
|
|
virtual TMask* get_mask();
|
|
|
|
public:
|
|
virtual bool preprocess_config (TMask& mask, TConfig& config);
|
|
virtual bool postprocess_config (TMask& mask, TConfig& config);
|
|
virtual bool user_create( );
|
|
virtual bool user_destroy( );
|
|
|
|
TConf_Hardy() : TConfig_application(CONFIG_DITTA), _ch(NULL) { }
|
|
virtual ~TConf_Hardy() { }
|
|
};
|
|
|
|
TMask* TConf_Hardy::get_mask()
|
|
{
|
|
return _ch;
|
|
}
|
|
|
|
TMask* TConf_Hardy::create_mask(const TFilename& f)
|
|
{
|
|
if (_ch == NULL)
|
|
_ch = new TConf_Hardy_mask(f);
|
|
return _ch;
|
|
}
|
|
|
|
bool TConf_Hardy::preprocess_config (TMask& mask, TConfig& config)
|
|
{
|
|
return true;
|
|
}
|
|
|
|
bool TConf_Hardy::postprocess_config (TMask& mask, TConfig& config)
|
|
{
|
|
return true;
|
|
}
|
|
|
|
bool TConf_Hardy::user_create( )
|
|
{
|
|
TConfig cfg(CONFIG_DITTA, "ha");
|
|
cfg.set("EdMask", "ha0200a");
|
|
return true;
|
|
}
|
|
|
|
bool TConf_Hardy::user_destroy( )
|
|
{
|
|
if (_ch != NULL)
|
|
delete _ch;
|
|
return true;
|
|
}
|
|
|
|
int ha0200(int argc, char* argv[])
|
|
{
|
|
TConf_Hardy configapp;
|
|
configapp.run(argc, argv, TR("Configurazione modulo"));
|
|
return 0;
|
|
} |