1 2 3 4 5 6 7 8 9 10 11 12
| void ClamavView::ShowModuleWidget() {
QItemSelectionModel *selection = console->ui.treeView->selectionModel();
QModelIndex indexElementSelectionne = selection->currentIndex();
QVariant elementSelectionne = console->modele->data(
indexElementSelectionne, Qt::DisplayRole);
// QMessageBox::information(this, "Titre de la fenêtre",
// "Bonjour et bienvenue à tous les Zéros !");
if (elementSelectionne.toString() == GetNameModule()) {
QAction *action = new QAction(this->GetNameModule(), console);
selection->connect(action, SIGNAL(clicked()), this, SLOT(InsertWidgetModule()));
}
} |
Partager