| 346 | } |
| 347 | |
| 348 | void VcsPluginHelper::history(const VcsRevision& rev) |
| 349 | { |
| 350 | Q_D(VcsPluginHelper); |
| 351 | |
| 352 | SINGLEURL_SETUP_VARS |
| 353 | auto* dlg = new QDialog(ICore::self()->uiController()->activeMainWindow()); |
| 354 | dlg->setAttribute(Qt::WA_DeleteOnClose); |
| 355 | dlg->setWindowTitle(i18nc("@title:window %1: path or URL, %2: name of a version control system", |
| 356 | "%2 History (%1)", url.toDisplayString(QUrl::PreferLocalFile), iface->name())); |
| 357 | KDevelop::restoreAndAutoSaveGeometry(*dlg, QStringLiteral("VCS"), QStringLiteral("HistoryDialog")); |
| 358 | |
| 359 | auto *mainLayout = new QVBoxLayout(dlg); |
| 360 | |
| 361 | auto* logWidget = new KDevelop::VcsEventWidget(url, rev, iface, dlg); |
| 362 | mainLayout->addWidget(logWidget); |
| 363 | |
| 364 | auto buttonBox = new QDialogButtonBox(QDialogButtonBox::Close); |
| 365 | dlg->connect(buttonBox, &QDialogButtonBox::accepted, dlg, &QDialog::accept); |
| 366 | dlg->connect(buttonBox, &QDialogButtonBox::rejected, dlg, &QDialog::reject); |
| 367 | mainLayout->addWidget(buttonBox); |
| 368 | |
| 369 | dlg->show(); |
| 370 | } |
| 371 | |
| 372 | void VcsPluginHelper::annotation() |
| 373 | { |
no test coverage detected