Since message methods are also virtual, it may work
As you can see in ASerge's and my posts, it does not work in objfpc mode -- when the message method is private in parent class you cannot use inherited. However, in delphi mode you can (but only without the method name).
This difference between modes doesn't seem to be documented. However, it was probably made so intentionally -- for Delphi compatibility. If I remember well (I don't have Delphi any more), in VCL components message methods are almost always declared in private section, but this doesn't prevent overriding them in derived classes, this is allowed in Delphi. In LCL however, these methods are usually declared in
published protected section (but not always, not in this case).
Edit: corrected lapsus - protected instead of published