mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-11 15:27:54 +00:00
Merge pull request #6689 from briankendall/fix_macos_addnewtorrentdialog_bug
Fix for macOS-specific bug in AddNewTorrentDialog
This commit is contained in:
commit
67f44e03a2
@ -577,6 +577,10 @@ void AddNewTorrentDialog::renameSelectedFile()
|
|||||||
|
|
||||||
void AddNewTorrentDialog::setdialogPosition()
|
void AddNewTorrentDialog::setdialogPosition()
|
||||||
{
|
{
|
||||||
|
// In macOS, AddNewTorrentDialog is a sheet, not a window. Moving it
|
||||||
|
// causes very bad things to happen, especially if AddNewTorrentDialog is
|
||||||
|
// on a secondary monitor.
|
||||||
|
#ifndef Q_OS_MAC
|
||||||
qApp->processEvents();
|
qApp->processEvents();
|
||||||
QPoint center(Utils::Misc::screenCenter(this));
|
QPoint center(Utils::Misc::screenCenter(this));
|
||||||
// Adjust y
|
// Adjust y
|
||||||
@ -590,6 +594,7 @@ void AddNewTorrentDialog::setdialogPosition()
|
|||||||
center.setY(0);
|
center.setY(0);
|
||||||
}
|
}
|
||||||
move(center);
|
move(center);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void AddNewTorrentDialog::populateSavePathComboBox()
|
void AddNewTorrentDialog::populateSavePathComboBox()
|
||||||
|
Loading…
Reference in New Issue
Block a user