mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-06-29 18:09:59 +03:00
fix(macos): fix margins on macos
Signed-off-by: DioEgizio <83089242+DioEgizio@users.noreply.github.com>
(cherry picked from commit b13f40df51)
This commit is contained in:
parent
4898f25e5f
commit
fe4e7bc51b
3 changed files with 18 additions and 5 deletions
|
|
@ -61,8 +61,10 @@ ResourceDownloadDialog::ResourceDownloadDialog(QWidget* parent, const std::share
|
|||
|
||||
setWindowIcon(QIcon::fromTheme("new"));
|
||||
|
||||
// small margins look ugly on macOS on modal windows
|
||||
#ifndef Q_OS_MACOS
|
||||
m_buttons.setContentsMargins(0, 0, 6, 6);
|
||||
|
||||
#endif
|
||||
// Bonk Qt over its stupid head and make sure it understands which button is the default one...
|
||||
// See: https://stackoverflow.com/questions/24556831/qbuttonbox-set-default-button
|
||||
auto OkButton = m_buttons.button(QDialogButtonBox::Ok);
|
||||
|
|
@ -116,7 +118,10 @@ void ResourceDownloadDialog::reject()
|
|||
// won't work with subclasses if we put it in this ctor.
|
||||
void ResourceDownloadDialog::initializeContainer()
|
||||
{
|
||||
// small margins look ugly on macOS on modal windows
|
||||
#ifndef Q_OS_MACOS
|
||||
layout()->setContentsMargins(0, 0, 0, 0);
|
||||
#endif
|
||||
|
||||
m_container = new PageContainer(this, {}, this);
|
||||
m_container->setSizePolicy(QSizePolicy::Policy::Preferred, QSizePolicy::Policy::Expanding);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue