mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-18 11:39:09 +02:00
Qt: avoid crash if LCLObject dissappeared inside SlotKey()
git-svn-id: trunk@28679 -
This commit is contained in:
parent
f7e1630363
commit
f3bb450103
@ -2556,8 +2556,13 @@ begin
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
{ Also sends a utf-8 key event for key down }
|
||||
|
||||
{ if our LCLObject dissappeared in the meantime just exit, otherwise
|
||||
we'll run into problems.}
|
||||
if (LCLObject = nil) then
|
||||
Exit(False);
|
||||
|
||||
{ Also sends a utf-8 key event for key down }
|
||||
if (QEvent_type(Event) = QEventKeyPress) and (Length(Text) <> 0) then
|
||||
begin
|
||||
UTF8Text := UTF16ToUTF8(Text);
|
||||
|
Loading…
Reference in New Issue
Block a user