diff options
| author | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2023-10-24 17:09:13 +0200 |
|---|---|---|
| committer | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2023-11-12 18:40:03 +0200 |
| commit | 0366b554c936e3257797f9c281c1cbd76e426dd3 (patch) | |
| tree | a4d61889559ac67692d23aabc59921ecd7568282 /src/widgets/doc/snippets/qtablewidget-using/main.cpp | |
| parent | b49211c12543c3369b286b507c4277c66ef9fdef (diff) | |
macOS: Respect QPlatformDialogHelper::ButtonLayout in native alerts
The buttons in QMessageDialogOptions do not have any order that we
can rely on. The standard buttons is just a bit mask, so any ordering
done on the QMessageBox side is lost. The custom buttons are ordered
in the same order the user added them, but this is not really the
order we want them to appear in the dialog either, as we have a
well defined order between roles provided by QPlatformDialogHelper.
We now follow the QPlatformDialogHelper::ButtonLayout order for
macOS, using the same heuristics for multiple Accept role buttons
as QDialogButtonBox.
For buttons with the same role, QMessageBox will respect the order
they were added in, but this is not something we can do for the
standard buttons, as long as they are flattened to a bit mask.
Pick-to: 6.6 6.5
Change-Id: I401f202a7c2d83dc253e988531ad145624c97580
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Diffstat (limited to 'src/widgets/doc/snippets/qtablewidget-using/main.cpp')
0 files changed, 0 insertions, 0 deletions
