assoc.cpp Corretta la aggiunta di un oggetto per reference

golem.cpp     Aggiunto messaggio di DDE


git-svn-id: svn://10.65.10.50/trunk@4142 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
guy 1997-02-19 11:55:38 +00:00
parent 6723a7cfea
commit 4cfcdbb371
2 changed files with 12 additions and 2 deletions

View File

@ -155,6 +155,11 @@ bool TAssoc_array::add(
bool TAssoc_array::add(const char* key, const TObject& obj, bool force)
{
bool isnew = FALSE;
THash_object* o = _lookup(key,isnew,TRUE);
if (!isnew && !force)
return TRUE;
return add(key,obj.dup(),force);
}

View File

@ -287,13 +287,18 @@ HIDDEN BOOLEAN hook(HWND hwnd,
CUR_DDE->do_ack(wparam);
normal_process = FALSE;
}
break;
break;
case WM_DDE_DATA:
{
ATOM i = HIWORD(lparam); if (i) GlobalDeleteAtom(i);
}
break;
case WM_DDE_EXECUTE:
{
const TString cmd((const char*)lparam);
DDEACK ack; memset(&ack, 0, sizeof(ack));
ack.fAck = CUR_DDE->do_execute(wparam, cmd);
// Ritorna indietro l'handle globale che verra' distrutto dal chiamante
// Ritorna indietro l'handle globale che verra' distrutto dal chiamante
PostMessage((HWND)wparam, WM_DDE_ACK, (WPARAM)hwnd, lparam);
normal_process = FALSE;
}