golem.cpp Reindentato caricamento funzioni da DLL
mask.cpp Velocizzato test di autosave dei campi strings.* Aggiunti i metodi TFilename::exist e TFilename::search_in_path defmask.h Aggiunto DLG_EMAIL urldefid.h Aggiunto BMP_EMAIL default.url Aggiunta email.bmp e tolte le tre bitmap dei libri ATTENZIONE: Il file email.bmp e' disponibile, per lo gaudio de li frati tutti, nell'antica biblioteca f:\p.due\bmp git-svn-id: svn://10.65.10.50/trunk@5646 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
3ff0f077de
commit
1ea0f9dc35
@ -108,9 +108,9 @@ image BMP_MODULE1 QRESDIR"module1.bmp"
|
||||
image BMP_MODULE2 QRESDIR"module2.bmp"
|
||||
image BMP_MODULE3 QRESDIR"module3.bmp"
|
||||
image BMP_MODULE4 QRESDIR"module4.bmp"
|
||||
image BMP_BOOK1 QRESDIR"book1.bmp"
|
||||
image BMP_BOOK2 QRESDIR"book2.bmp"
|
||||
image BMP_BOOK3 QRESDIR"book3.bmp"
|
||||
//image BMP_BOOK1 QRESDIR"book1.bmp"
|
||||
//image BMP_BOOK2 QRESDIR"book2.bmp"
|
||||
//image BMP_BOOK3 QRESDIR"book3.bmp"
|
||||
image BMP_MODULE QRESDIR"module.bmp"
|
||||
image BMP_EDIT QRESDIR"edit.bmp"
|
||||
image BMP_LINK QRESDIR"link.bmp"
|
||||
@ -120,6 +120,7 @@ image BMP_RECALC QRESDIR"recalc.bmp"
|
||||
image BMP_OLE QRESDIR"ole.bmp"
|
||||
image BMP_LENTE QRESDIR"lente.bmp"
|
||||
image BMP_FAX QRESDIR"fax.bmp"
|
||||
image BMP_EMAIL QRESDIR"email.bmp"
|
||||
|
||||
#scan <xil.h>
|
||||
#transparent $$$
|
||||
|
@ -30,6 +30,7 @@
|
||||
#define DLG_RECALC 26 /* TAG del bottone Ricalcola */
|
||||
#define DLG_F8 27 /* TAG del bottone <Ricerca zoom> */
|
||||
#define DLG_FAX 28 /* TAG del bottone <Fax> */
|
||||
#define DLG_EMAIL 29 /* TAG del bottone <Posta> */
|
||||
#define DLG_USER 100 /* TAG del primo controllo definito dall'utente */
|
||||
|
||||
/* @M
|
||||
|
@ -153,7 +153,9 @@ HIDDEN word file2icon(const char* filename)
|
||||
|
||||
HIDDEN word mail2icon()
|
||||
{
|
||||
word icon = 0;
|
||||
word icon = 0;
|
||||
|
||||
// Non so se questo debba rimanere
|
||||
TFilename key;
|
||||
if (get_reg_key(HKEY_CLASSES_ROOT, "msgfile\\shell\\open\\command", key) == ERROR_SUCCESS)
|
||||
{
|
||||
@ -161,6 +163,9 @@ HIDDEN word mail2icon()
|
||||
if (space) key.cut(space);
|
||||
icon = file2icon(key);
|
||||
}
|
||||
|
||||
if (icon == 0)
|
||||
icon = file2icon(".msg");
|
||||
if (icon == 0)
|
||||
icon = file2icon(".mmf");
|
||||
return icon;
|
||||
@ -581,11 +586,9 @@ bool TGolem_field::on_key(KEY key)
|
||||
TMask* msk = new TGolem_mask;
|
||||
TSheet_field& sheet = msk->sfield(F_SHEET);
|
||||
|
||||
TToken_string tmp = get();
|
||||
TToken_string tmp(get(), '\n');
|
||||
if (roman())
|
||||
{
|
||||
tmp.separator('\n');
|
||||
// for (const char* row = tmp.get(0); row; row = tmp.get())
|
||||
FOR_EACH_TOKEN(tmp, row)
|
||||
{
|
||||
if (*row > ' ')
|
||||
@ -594,10 +597,8 @@ bool TGolem_field::on_key(KEY key)
|
||||
if (msk->run() == K_ENTER)
|
||||
{
|
||||
tmp.cut(0);
|
||||
// for (int r = 0; r < sheet.items(); r++)
|
||||
FOR_EACH_SHEET_ROW(sheet, r, row)
|
||||
{
|
||||
// TToken_string& row = sheet.row(r);
|
||||
if ((*row)[0] > ' ')
|
||||
tmp.add(*row);
|
||||
}
|
||||
@ -674,30 +675,18 @@ bool TMail_message::load_mapi(void)
|
||||
if ((DWORD)err < 32)
|
||||
return FALSE;
|
||||
|
||||
if (!(lpfnMAPILogon = (LPMAPILOGON) GetProcAddress (_hlibMAPI, "MAPILogon")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPILogoff = (LPMAPILOGOFF) GetProcAddress (_hlibMAPI, "MAPILogoff")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPISendMail = (LPMAPISENDMAIL) GetProcAddress (_hlibMAPI, "MAPISendMail")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPISendDocuments = (LPMAPISENDDOCUMENTS) GetProcAddress (_hlibMAPI, "MAPISendDocuments")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPIFindNext = (LPMAPIFINDNEXT) GetProcAddress (_hlibMAPI, "MAPIFindNext")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPIReadMail = (LPMAPIREADMAIL) GetProcAddress (_hlibMAPI, "MAPIReadMail")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPISaveMail = (LPMAPISAVEMAIL) GetProcAddress (_hlibMAPI, "MAPISaveMail")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPIDeleteMail = (LPMAPIDELETEMAIL) GetProcAddress (_hlibMAPI, "MAPIDeleteMail")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPIFreeBuffer = (LPMAPIFREEBUFFER) GetProcAddress (_hlibMAPI, "MAPIFreeBuffer")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPIAddress = (LPMAPIADDRESS) GetProcAddress (_hlibMAPI, "MAPIAddress")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPIDetails = (LPMAPIDETAILS) GetProcAddress (_hlibMAPI, "MAPIDetails")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPIResolveName = (LPMAPIRESOLVENAME) GetProcAddress (_hlibMAPI, "MAPIResolveName")))
|
||||
return FALSE;
|
||||
if (!(lpfnMAPILogon = (LPMAPILOGON)GetProcAddress (_hlibMAPI, "MAPILogon"))) return FALSE;
|
||||
if (!(lpfnMAPILogoff = (LPMAPILOGOFF)GetProcAddress (_hlibMAPI, "MAPILogoff"))) return FALSE;
|
||||
if (!(lpfnMAPISendMail = (LPMAPISENDMAIL)GetProcAddress (_hlibMAPI, "MAPISendMail"))) return FALSE;
|
||||
if (!(lpfnMAPISendDocuments = (LPMAPISENDDOCUMENTS) GetProcAddress (_hlibMAPI, "MAPISendDocuments"))) return FALSE;
|
||||
if (!(lpfnMAPIFindNext = (LPMAPIFINDNEXT)GetProcAddress (_hlibMAPI, "MAPIFindNext"))) return FALSE;
|
||||
if (!(lpfnMAPIReadMail = (LPMAPIREADMAIL)GetProcAddress (_hlibMAPI, "MAPIReadMail"))) return FALSE;
|
||||
if (!(lpfnMAPISaveMail = (LPMAPISAVEMAIL)GetProcAddress (_hlibMAPI, "MAPISaveMail"))) return FALSE;
|
||||
if (!(lpfnMAPIDeleteMail = (LPMAPIDELETEMAIL)GetProcAddress (_hlibMAPI, "MAPIDeleteMail"))) return FALSE;
|
||||
if (!(lpfnMAPIFreeBuffer = (LPMAPIFREEBUFFER)GetProcAddress (_hlibMAPI, "MAPIFreeBuffer"))) return FALSE;
|
||||
if (!(lpfnMAPIAddress = (LPMAPIADDRESS)GetProcAddress (_hlibMAPI, "MAPIAddress"))) return FALSE;
|
||||
if (!(lpfnMAPIDetails = (LPMAPIDETAILS)GetProcAddress (_hlibMAPI, "MAPIDetails"))) return FALSE;
|
||||
if (!(lpfnMAPIResolveName = (LPMAPIRESOLVENAME)GetProcAddress (_hlibMAPI, "MAPIResolveName"))) return FALSE;
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
@ -1326,10 +1326,10 @@ void TMask::autosave(TRelation& r) const
|
||||
// tenta di effettuare il save dei campi Edit hidden:
|
||||
// salva il nuovo valore solo se il precedente era blank
|
||||
TEditable_field& e = (TEditable_field&)f;
|
||||
if (e.field() != NULL) {
|
||||
TString str;
|
||||
str = l.field()->read(r);
|
||||
save = str.empty();
|
||||
if (e.field() != NULL)
|
||||
{
|
||||
const char* str = l.field()->read(r);
|
||||
save = *str == '\0';
|
||||
}
|
||||
}
|
||||
if (save)
|
||||
|
@ -1237,13 +1237,26 @@ const TFilename& TFilename::make_absolute_path()
|
||||
{
|
||||
if (is_relative_path())
|
||||
{
|
||||
const TString saved(*this);
|
||||
const TString saved(_str);
|
||||
getcwd(get_buffer(), size());
|
||||
add(saved);
|
||||
}
|
||||
return *this;
|
||||
}
|
||||
|
||||
bool TFilename::exist() const
|
||||
{
|
||||
return ::fexist(_str);
|
||||
}
|
||||
|
||||
bool TFilename::search_in_path(TFilename& path) const
|
||||
{
|
||||
_searchenv(_str, "PATH", path.get_buffer());
|
||||
if (path.empty())
|
||||
_searchenv(_str, "path", path.get_buffer());
|
||||
return path.not_empty();
|
||||
}
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////
|
||||
// Token string
|
||||
|
@ -416,6 +416,10 @@ public:
|
||||
bool is_relative_path() const { return !is_absolute_path(); }
|
||||
// @cmember Trasforma un path da relativo ad assoluto
|
||||
const TFilename& make_absolute_path();
|
||||
// @cmember Testa se il file esiste
|
||||
bool exist() const;
|
||||
// @cmember Cerca nel path il nome del file corrente e scrive il path assoluto in path
|
||||
bool search_in_path(TFilename& path) const;
|
||||
|
||||
// @cmember Ritorna il nome del file
|
||||
const char* name() const;
|
||||
|
@ -70,6 +70,7 @@
|
||||
#define BMP_1 136
|
||||
#define BMP_2 137
|
||||
#define BMP_3 138
|
||||
#define BMP_EMAIL 139
|
||||
#define BMP_SAVERECDN 153
|
||||
#define BMP_DELRECDN 154
|
||||
#define BMP_NEWRECDN 155
|
||||
|
Loading…
x
Reference in New Issue
Block a user