Close button response to [esc] on Carbon
Original Reporter info from Mantis: djenkins @dfjenkins
-
Reporter name: David Jenkins
Original Reporter info from Mantis: djenkins @dfjenkins
- Reporter name: David Jenkins
Description:
If a button is created and has both the Default and Cancel properties set to true before its parent is assigned (in the button's constructor or creating the button at runtime), the Cancel button can be incorrectly cleared. In that situation, the button's FDefault and FCancel properties are set, but Parent isn't assigned, so it can't update the DefaultControl/CancelControl properties. When it does finally calls TCustomButton.UpdateDefaultCancel, SetDefaultControl calls UpdateRolesForForm, which only returns [ccrfDefault], since CancelControl hasn't been assigned yet.
Suggest fix is to save off FCancel and used stored value
Patch against rev 36681 is attached
Mantis conversion info:
- Mantis ID: 21739
- Version: 0.9.30.5 (SVN)
- Fixed in version: 1.1 (SVN)
- Fixed in revision: 36811 (#b00855a5)
- Monitored by: » @dfjenkins (David Jenkins)