mirror of
https://github.com/Artikash/Textractor.git
synced 2024-12-23 08:54:12 +08:00
fix extension loading bug
This commit is contained in:
parent
703fc47972
commit
e20f16da80
@ -144,9 +144,9 @@ void ExtenWindow::dropEvent(QDropEvent* event)
|
||||
{
|
||||
QFileInfo extenFile = file.toLocalFile();
|
||||
if (extenFile.suffix() != "dll") continue;
|
||||
if (QFile::exists(extenFile.fileName()) && extenFile.absolutePath() != QDir::currentPath())
|
||||
if (extenFile.absolutePath() != QDir::currentPath())
|
||||
{
|
||||
if (QMessageBox::question(this, EXTENSIONS, CONFIRM_EXTENSION_OVERWRITE) == QMessageBox::Yes) QFile::remove(extenFile.fileName());
|
||||
if (QFile::exists(extenFile.fileName()) && QMessageBox::question(this, EXTENSIONS, CONFIRM_EXTENSION_OVERWRITE) == QMessageBox::Yes) QFile::remove(extenFile.fileName());
|
||||
if (!QFile::copy(extenFile.absoluteFilePath(), extenFile.fileName())) QMessageBox::warning(this, EXTENSIONS, EXTENSION_WRITE_ERROR);
|
||||
}
|
||||
if (Load(extenFile.completeBaseName())) Sync();
|
||||
|
Loading…
x
Reference in New Issue
Block a user