Fix deletionconfirmationdlg position

Fix autoexpandabledialog position
Fix previewselect position
This commit is contained in:
Chocobo1 2015-10-26 16:43:41 +08:00
parent a902eb6b2b
commit 46abe42a54
7 changed files with 20 additions and 112 deletions

View file

@ -83,7 +83,7 @@ PreviewSelect::PreviewSelect(QWidget* parent, BitTorrent::TorrentHandle *const t
}
if (!previewListModel->rowCount()) {
QMessageBox::critical(0, tr("Preview impossible"), tr("Sorry, we can't preview this file"));
QMessageBox::critical(this->parentWidget(), tr("Preview impossible"), tr("Sorry, we can't preview this file"));
close();
}
connect(this, SIGNAL(readyToPreviewFile(QString)), parent, SLOT(previewFile(QString)));
@ -120,7 +120,7 @@ void PreviewSelect::on_previewButton_clicked() {
if (QFile::exists(path))
emit readyToPreviewFile(path);
else
QMessageBox::critical(0, tr("Preview impossible"), tr("Sorry, we can't preview this file"));
QMessageBox::critical(this->parentWidget(), tr("Preview impossible"), tr("Sorry, we can't preview this file"));
close();
}