mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-16 14:49:07 +02:00
Qt5: better check for dangling handle pointer.
git-svn-id: trunk@54113 -
This commit is contained in:
parent
5dfff39ac5
commit
f439ee0b2f
@ -294,7 +294,8 @@ begin
|
||||
Result := False;
|
||||
if not WSCheckHandleAllocated(AWincontrol, 'GetText') then
|
||||
Exit;
|
||||
|
||||
if not QtWidgetSet.IsValidHandle(AWinControl.Handle) then
|
||||
exit;
|
||||
Result := not TQtWidget(AWinControl.Handle).getTextStatic;
|
||||
if Result then
|
||||
AText := UTF16ToUTF8(TQtWidget(AWinControl.Handle).getText);
|
||||
|
Loading…
Reference in New Issue
Block a user