81d17db674
Files correlati : sistemati bottoni mancanti in tutti i programmi di ba Ricompilazione Demo : [ ] Commento : git-svn-id: svn://10.65.10.50/trunk@16627 c028cbd2-c16b-5b4b-a496-9718f37d4682
95 lines
2.2 KiB
C++
Executable File
95 lines
2.2 KiB
C++
Executable File
#ifndef __BA1100_H
|
|
#define __BA1100_H
|
|
|
|
#ifndef __CONFIG_H
|
|
#include <config.h>
|
|
#endif
|
|
|
|
#ifndef __SHEET_H
|
|
#include <isam.h>
|
|
#endif
|
|
|
|
#ifndef __SHEET_H
|
|
#include <sheet.h>
|
|
#endif
|
|
|
|
#ifndef __MASKFLD_H
|
|
class TMask_field;
|
|
#endif
|
|
|
|
#include "ba1100a.h"
|
|
|
|
///////////////////////////////////////////////////////////
|
|
// TDir_sheet
|
|
///////////////////////////////////////////////////////////
|
|
|
|
class TDir_sheet : public TSheet
|
|
{
|
|
TTrec *_rec;
|
|
TDir *_dir;
|
|
FileDes _s_dir;
|
|
long _items;
|
|
|
|
protected:
|
|
virtual long get_items() const { return _items; }
|
|
virtual void get_row(long n, TToken_string& r);
|
|
|
|
public:
|
|
TDir* dir() const { return _dir; }
|
|
TTrec* rec() const { return _rec; }
|
|
void set_items(long items) { _items = items; }
|
|
void add();
|
|
void rebuild() { _items = _dir->items();}
|
|
|
|
TDir_sheet(const char* title, bool superprassi, const char* col = "N.@3R|Nome@20|EOD@7R|EOX@7R|Lung.@7R|Descrizione@43|Formula@33|Flags@7R");
|
|
virtual ~TDir_sheet();
|
|
};
|
|
|
|
class TRec_sheet : public TObject
|
|
{
|
|
TTrec *_rec;
|
|
TTrec *_rec_old;
|
|
TDir *_dir;
|
|
bool _comfile;
|
|
TConfig *_descr;
|
|
static TMask *_mask;
|
|
TFilename _descfname;
|
|
TString16 _tab;
|
|
bool _external;
|
|
|
|
protected:
|
|
bool check_key_expr(int key, const char* key_expr);
|
|
static bool key_notify(TSheet_field& s, int r, KEY k);
|
|
static bool fld_notify(TSheet_field& s, int r, KEY k);
|
|
void save();
|
|
void save_desc();
|
|
|
|
virtual long get_items() const { return _rec->fields(); }
|
|
|
|
public:
|
|
TDir* dir() const { return _dir; }
|
|
TTrec* rec() const { return _rec; }
|
|
const char* descfname() const { return _descfname;}
|
|
const char* tab() const { return _tab; }
|
|
void edit();
|
|
|
|
TRec_sheet(int logicnum, const char* tab);
|
|
TRec_sheet(TExternisamfile* file);
|
|
virtual ~TRec_sheet();
|
|
};
|
|
|
|
class TEdit_file : public TObject
|
|
{
|
|
protected:
|
|
void edit_record(TRectype& rec);
|
|
bool browse_cursor(TCursor& cur, const TFilename& name);
|
|
|
|
public:
|
|
bool browse_file(int logicnum, const TFilename& name, const TString& tab);
|
|
bool browse_file(TExternisamfile* file, const TFilename& name);
|
|
TEdit_file() {}
|
|
virtual ~TEdit_file() {}
|
|
};
|
|
|
|
#endif
|