fix createKMessageBox focus widget inconsistency
Summary:
When creating dialogs via createKMessageBox in case the QDialogButtonBox parameter is parentless, the focus shifts from the left most button to any of the following in this order:
- Message Label (if the AllowLink flag is present)
- The string list (if it is not empty)
- Checkbox confirmation (If present)
- Left most action button
Moving the call of setParent of the QDialogButtonBox before any of the above mentioned widgets is created fixes this inconsistency.
Test Plan:
A use case where an application sets a default button but the checkbox is still selected instead is Dolphin.
- Open more than 1 tab in Dolphin
- Close Dolphin
Expected: The quit button is focused
Actual: Checkbox "Do not ask again" is focused
Reviewers: Frameworks, ngraham, aacid, VDG, rkflx, subdiff
Reviewed By: ngraham, rkflx, subdiff
Subscribers: elvisangelaccio, rkflx, abetts, subdiff, ngraham, aacid, Frameworks
Tags: Frameworks
Differential Revision: https://phabricator.kde.org/D7828