void MarkerView::markerSelectionChanged() { MarkerItem* item = (MarkerItem*) table->currentItem(); if (item == 0) { // never triggered editTick->setValue(0); editSMPTE->setValue(0); editName->setText(QString("")); lock->setChecked(false); editSMPTE->setEnabled(false); editTick->setEnabled(false); lock->setEnabled(false); editName->setEnabled(false); } else { editTick->setValue(item->tick()); editSMPTE->setValue(item->tick()); editName->setText(item->name()); editName->setEnabled(true); lock->setChecked(item->lock()); lock->setEnabled(true); //printf("MarkerView::markerSelectionChanged item->lock:%d\n", item->lock()); editSMPTE->setEnabled(item->lock()); editTick->setEnabled(!item->lock()); } }
void MarkerView::clicked(QTreeWidgetItem* i) { MarkerItem* item = (MarkerItem*) i; if (item == 0) { table->clearSelection(); return; } Pos p(item->tick(), true); song->setPos(0, p, true, true, false); }