void MVCrossCorrelogramsWidget::keyPressEvent(QKeyEvent *evt)
{
	if (evt->key()==Qt::Key_Left) {
		setCurrentUnit(this->currentUnit()-1);
	}
	else if (evt->key()==Qt::Key_Right) {
		setCurrentUnit(this->currentUnit()+1);
	}
	else if (evt->key()==Qt::Key_Up) {
		setCurrentUnit(this->currentUnit()-d->m_num_columns);
	}
	else if (evt->key()==Qt::Key_Down) {
		setCurrentUnit(this->currentUnit()+d->m_num_columns);
	}
}
void KLFUnitChooser::changeEvent(QEvent *event)
{
  if (event->type() == QEvent::EnabledChange) {
    if (isEnabled() && !pDelayedUnitSet.isEmpty()) {
      setCurrentUnit(pDelayedUnitSet);
      pDelayedUnitSet = QString();
    }
  }
  QComboBox::changeEvent(event);
}
void MVCrossCorrelogramsWidget::slot_histogram_view_clicked()
{
	int num=sender()->property("unit_number").toInt();
	setCurrentUnit(num);
}