新增虚拟机日志输出和读取功能(不使用安装器)

This commit is contained in:
2023-11-07 19:34:28 +08:00
parent 4853cafb67
commit 134fff9f17
5 changed files with 32 additions and 11 deletions

View File

@@ -344,7 +344,20 @@ void MainWindow::on_actionVMLog_triggered()
return;
}
file.open(QIODevice::ReadOnly);
QInputDialog::getMultiLineText(this, "日志", "虚拟机日志",file.readAll());
QInputDialog::getMultiLineText(this, "安装日志", "虚拟机安装日志",file.readAll());
file.close();
}
void MainWindow::on_actionVMRunlLog_triggered()
{
QFile file("/tmp/windows-virtual-machine-installer-for-wine-runner-run.log");
if(!file.exists()){
QMessageBox::information(this, "提示", "没有日志文件");
return;
}
file.open(QIODevice::ReadOnly);
QInputDialog::getMultiLineText(this, "运行日志", "虚拟机运行日志",file.readAll());
file.close();
}