- install global event filter on all systems (not only win) to catch release events
- fix crash in RawImage_FromBitmap

git-svn-id: trunk@13738 -
This commit is contained in:
paul 2008-01-13 13:31:01 +00:00
parent b1c2ed3d9b
commit f895295167
2 changed files with 8 additions and 8 deletions

View File

@ -391,7 +391,9 @@ begin
begin
WorkMask := TQtImage.Create;
WorkMask.CopyFrom(Mask.Handle, ARect.Left, ARect.Top, Width, Height);
end;
end
else
WorkMask := nil;
end;
Desc.Width := WorkImage.width;

View File

@ -104,16 +104,14 @@ begin
FOldFocusWidget := nil;
{This hook crashes linux & darwin ocasionally !
todo: check what happens with win32
and possibly remove this hook at all.
Tabs works under linux & darwin without this hook}
{$ifdef windows}
{
check whether this hook crashes on linux & darwin and why it is so
we need this hook to catch release messages
}
// install global event filter
FHook := QObject_hook_create(App);
TEventFilterMethod(Method) := @EventFilter;
QObject_hook_hook_events(FHook, Method);
{$endif}
end;
{------------------------------------------------------------------------------
@ -266,7 +264,7 @@ begin
end;
LCLQt_Destroy:
begin
AObject := TQtObject(QLCLMessageEvent_getWParam(QLCLMessageEventH(Event)));
AObject := TQtObject(Pointer(QLCLMessageEvent_getWParam(QLCLMessageEventH(Event))));
//WriteLn('Catched free for: ', PtrUInt(AObject), ' : ', AObject.ClassName);
AObject.Free;
Result := True;