##// END OF EJS Templates
Fixes
trabillard -
r1141:00ce9b74612e
parent child
Show More
@@ -45,9 +45,10 CatalogueEventsWidget::CatalogueEventsWidget(QWidget *parent)
45
45
46 connect(ui->tableWidget, &QTableWidget::itemSelectionChanged, [this]() {
46 connect(ui->tableWidget, &QTableWidget::itemSelectionChanged, [this]() {
47 auto selection = ui->tableWidget->selectedRanges();
47 auto selection = ui->tableWidget->selectedRanges();
48 auto isSingleSelection = selection.count() == 1 && selection.first().rowCount() == 1;
48 auto isNotMultiSelection
49 ui->btnChart->setEnabled(isSingleSelection);
49 = selection.isEmpty() || (selection.count() == 1 && selection.first().rowCount() == 1);
50 ui->btnTime->setEnabled(isSingleSelection);
50 ui->btnChart->setEnabled(isNotMultiSelection);
51 ui->btnTime->setEnabled(isNotMultiSelection);
51 });
52 });
52
53
53 Q_ASSERT(impl->columnNames().count() == (int)CatalogueEventsWidgetPrivate::Column::NbColumn);
54 Q_ASSERT(impl->columnNames().count() == (int)CatalogueEventsWidgetPrivate::Column::NbColumn);
@@ -8,12 +8,12 CatalogueExplorer::CatalogueExplorer(QWidget *parent)
8 ui->setupUi(this);
8 ui->setupUi(this);
9
9
10 connect(ui->catalogues, &CatalogueSideBarWidget::catalogueSelected, [this](auto name) {
10 connect(ui->catalogues, &CatalogueSideBarWidget::catalogueSelected, [this](auto name) {
11 ui->inspector->setEvent(name);
11 ui->inspector->setCatalogue(name);
12 ui->events->populateWithCatalogue(name);
12 ui->events->populateWithCatalogue(name);
13 });
13 });
14
14
15 connect(ui->events, &CatalogueEventsWidget::eventSelected,
15 connect(ui->events, &CatalogueEventsWidget::eventSelected,
16 [this](auto name) { ui->inspector->setCatalogue(name); });
16 [this](auto name) { ui->inspector->setEvent(name); });
17 }
17 }
18
18
19 CatalogueExplorer::~CatalogueExplorer()
19 CatalogueExplorer::~CatalogueExplorer()
General Comments 3
Under Review
author

Auto status change to "Under Review"

Approved

Status change > Approved

You need to be logged in to leave comments. Login now