avoid exception when subclass has no focus method, fixes #16816 on trunk !strict