Unit 'msegui' Package
[Overview][Constants][Types][Classes][Procedures and functions][Index] [#msegui]

twidget.canparentclose

Checks whether all descendant widgets accept losing focus, without raising onclosequery

Declaration

Source position: msegui.pas line 2280

public function twidget.canparentclose(

  const newfocus: twidget

):Boolean; overload;

function twidget.canparentclose: Boolean; overload;

Description

Checks whether all descendant widgets accept losing focus, without raising onclosequery: the currently focused widget is checked first with canclose if it is a descendant, then the remaining descendants. window.owner addresses the top level widget; if it is a tcustomform, window.owner.container.canparentclose checks all widgets of the form and does not fire onclosequery (window.owner.canparentclose does).


Documentation generated on: 2026-10-03