golem.cpp Aggiustato DDE Server
maskfld.cpp Sostituita TString80 con TSTring msksheet.cpp Corretta chiamata alla off_cell_handler nella on_key prefix.cpp Corretta ricerca nome tabelle sheet.cpp Sostituita una select con set_focus_rec git-svn-id: svn://10.65.10.50/trunk@2981 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
4d963df585
commit
7013930383
@ -340,6 +340,13 @@ bool TDDE::execute(const char* cmd) const
|
||||
return PostMessage((HWND)_server, WM_DDE_EXECUTE, (WPARAM)_hwnd, MAKELPARAM(0, hg));
|
||||
}
|
||||
|
||||
bool TDDE::start_server()
|
||||
{
|
||||
CHECK(_old_hook == NULL, "Non puoi iniziare due connessioni DDE");
|
||||
_old_hook = xvt_vobj_get_attr(NULL_WIN, ATTR_EVENT_HOOK);
|
||||
xvt_vobj_set_attr(NULL_WIN, ATTR_EVENT_HOOK, (long)hook);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void TDDE::terminate()
|
||||
{
|
||||
|
@ -118,6 +118,9 @@ public:
|
||||
// @cmember Chiude la connessione
|
||||
void terminate();
|
||||
|
||||
// @cmember Inizia a fornire i servizi di DDE server
|
||||
bool start_server();
|
||||
|
||||
word hwnd() const { return _hwnd; }
|
||||
|
||||
// @cmember Costruttore
|
||||
|
@ -2188,7 +2188,7 @@ KEY TBrowse::run()
|
||||
_cursor->read(_isgteq);
|
||||
|
||||
const TLocalisamfile& f = _cursor->file();
|
||||
TString80 caption(prefix().description(f.name()));
|
||||
TString caption(prefix().description(f.name()));
|
||||
if (!isalnum(caption[0]))
|
||||
caption = "Selezione";
|
||||
|
||||
|
@ -1811,8 +1811,8 @@ void TSheet_field::select(int r, bool scrollto)
|
||||
}
|
||||
|
||||
bool TSheet_field::on_key(KEY k)
|
||||
{
|
||||
if (k == K_TAB)
|
||||
{
|
||||
if (k == K_TAB && items() > 0)
|
||||
{
|
||||
if (focusdirty())
|
||||
{
|
||||
@ -1821,10 +1821,9 @@ bool TSheet_field::on_key(KEY k)
|
||||
return FALSE;
|
||||
}
|
||||
else
|
||||
if (items() > 0)
|
||||
select(0);
|
||||
}
|
||||
|
||||
|
||||
if (k == K_ROWEDIT && items() > 0)
|
||||
{
|
||||
select(items()-1);
|
||||
|
@ -368,10 +368,22 @@ const char* TPrefix::description(
|
||||
if (fexist(name.lower()))
|
||||
{
|
||||
TScanner m(name);
|
||||
while (m.line().left(2) != "PA"); // Find PAGE
|
||||
const int apicia = m.token().find('"')+1;
|
||||
const int apicic = m.token().find('"', apicia);
|
||||
n = m.token().sub(apicia, apicic);
|
||||
bool ok = TRUE;
|
||||
while (ok)
|
||||
{
|
||||
const TString& l2 = m.line().left(2);
|
||||
if (l2.empty())
|
||||
ok = FALSE;
|
||||
else
|
||||
if (l2 == "PA")
|
||||
break;
|
||||
}
|
||||
if (ok)
|
||||
{
|
||||
const int apicia = m.token().find('"')+1;
|
||||
const int apicic = m.token().find('"', apicia);
|
||||
n = m.token().sub(apicia, apicic);
|
||||
}
|
||||
}
|
||||
else n.cut(0);
|
||||
}
|
||||
|
@ -61,7 +61,7 @@ TString& TScanner::line(
|
||||
_line++;
|
||||
_token << __tmp_string;
|
||||
_token.trim();
|
||||
} while (_token.empty() && good());
|
||||
} while (_token.empty() && !eof());
|
||||
|
||||
_pushed = FALSE;
|
||||
|
||||
|
@ -990,7 +990,7 @@ KEY TCursor_sheet::run()
|
||||
{
|
||||
_records = _cursor->items();
|
||||
_cursor->freeze(TRUE);
|
||||
select(_cursor->pos());
|
||||
post_select(_cursor->pos());
|
||||
const KEY k = TSheet::run();
|
||||
_cursor->freeze(FALSE);
|
||||
return k;
|
||||
|
Loading…
x
Reference in New Issue
Block a user