Aggiunti i metodi: make_new_item(), copy_to_form_item() e dup() ai
TForm_item, per effettuare la copia di una sezione. Reso pretected il membro _section. Il tutto per l'errore MI3347. git-svn-id: svn://10.65.10.50/trunk@2746 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
a3ecc6379d
commit
cfb72fba44
@ -492,7 +492,7 @@ public:
|
||||
// @cmember Rimuove uno o tutti i campi da stampare (chiama <mf TArray::destroy>)
|
||||
void destroy_field(int n, bool c = TRUE)
|
||||
{ _item.destroy(n, c); }
|
||||
// @cmember Ritmuove tutti i campi da stampare (chiama <mf TArray::destroy>)
|
||||
// @cmember Rimuove tutti i campi da stampare (chiama <mf TArray::destroy>)
|
||||
void destroy_fields()
|
||||
{ _item.destroy(); }
|
||||
// @cmember Viene sostiuito il campo di posizione <p n> col campo <p f> (chiama <mf TArray::add>)
|
||||
@ -569,7 +569,7 @@ public:
|
||||
// @cmember Annulla (setta a -1) l'offset delle colonne se COLUMNWISE
|
||||
void reset_tabs();
|
||||
|
||||
// @cmember Opertatore di assegnamento
|
||||
// @cmember Operatore di assegnamento
|
||||
const TPrint_section& operator=(const TPrint_section& ps)
|
||||
{ return copy(ps); }
|
||||
// @cmember Costruttore
|
||||
@ -598,8 +598,6 @@ class TForm_item : public TObject
|
||||
|
||||
// @access:(INTERNAL) Private Member
|
||||
|
||||
// @cmember:(INTERNAL) Sezione da stampare (vedi <c TPrint_section>)
|
||||
TPrint_section* _section;
|
||||
// @cmember:(INTERNAL) Flag del campo (vedi <c TForm_flags>)
|
||||
TForm_flags _flag;
|
||||
// @cmember:(INTERNAL) Gruppi a cui appartiene il campo
|
||||
@ -611,6 +609,8 @@ class TForm_item : public TObject
|
||||
|
||||
// @access Protected Member
|
||||
protected:
|
||||
// @cmember:(INTERNAL) Sezione da stampare (vedi <c TPrint_section>)
|
||||
TPrint_section* _section;
|
||||
// @cmember Identificatore del campo
|
||||
short _id;
|
||||
// @cmember Coordinata X (in caratteri) del campo
|
||||
@ -658,9 +658,24 @@ protected:
|
||||
// @cmember Cerca nella definizione della variabile <p s> e ne ritorna
|
||||
// l'<p n>-esimo elemento (0=tipo, 1=valore, 2=descrizione)
|
||||
const char* get_special_item(const char* s, int n) const;
|
||||
|
||||
|
||||
// @cmember Crea un item (TForm_date, TForm_list...) e ne restituisce il puntatore
|
||||
// TForm_item. Va ridefinita per ogni classe derivata da TForm_item.
|
||||
// N.B. il membro _section deve rimanere protected, altrimenti le varie
|
||||
// make_new_item() non potranno essere compilate.
|
||||
virtual TForm_item* make_new_item() const;
|
||||
// @cmember Restituisce un puntatore a TForm_item, nel quale sono copiati tutti
|
||||
// i membri del presente oggetto. Viene chiamata dalla <mf TForm_item::dup>
|
||||
// All'interno di questa funzione vi e' una discriminazione sul tipo di classe
|
||||
// affinche' possa creare un opportuno item (data, lista, numero, stringa...).
|
||||
// E' ovvio che per tali ultimi casi e' necessario un cast. Chiama la <mf TForm_item::make_new_item>
|
||||
// per creare un nuovo item.
|
||||
TForm_item* copy_to_form_item() const;
|
||||
|
||||
// @access Public Member
|
||||
public:
|
||||
// @cmember Duplica un TForm_item. Chiama la <mf TForm_item::copy_to_form_item>
|
||||
virtual TObject* dup() const;
|
||||
// @cmember Ritorna il numero identificatore del campo
|
||||
short id() const
|
||||
{ return _id; }
|
||||
|
Loading…
x
Reference in New Issue
Block a user