Ejemplo n.º 1
0
void CPropertiesDialog::SetCamera(CCamera *pCamera )
{

  _pCamera = pCamera;
  
  setWindowTitle( _pCamera->_name);
  
  deleteControls();
  
  for( int i = 0; i < _pCamera->_cProperties.size(); i++ )
  {
    CPropertyControl *pSld = new CPropertyControl;
    switch( _pCamera->_cProperties[i]->_type )
    {
      case CProperty::BOOLEAN:
	pSld->Check = new QCheckBox(_pCamera->_cProperties[i]->_name );
	pSld->Check->setCheckState( _pCamera->_cProperties[i]->_value ? Qt::Checked : Qt::Unchecked );
	_PropertiesLayout->addWidget( pSld->Check);
	QObject::connect(pSld->Check, SIGNAL(stateChanged(int)), this, SLOT(OnClickedCheckkBox(int)));
	break;

      case CProperty::BUTTON:
	pSld->Push = new QPushButton(_pCamera->_cProperties[i]->_name );
	_PropertiesLayout->addWidget( pSld->Push);
	QObject::connect(pSld->Push, SIGNAL(released()), this, SLOT(OnPushButton()));
	break;

	
      default:
	pSld->Label = new QLabel( _pCamera->_cProperties[i]->_name);
	pSld->Slider = new QSlider(Qt::Horizontal);
	
	_PropertiesLayout->addWidget( pSld->Label);
	_PropertiesLayout->addWidget( pSld->Slider);
	pSld->Slider->setMinimum(_pCamera->_cProperties[i]->_minimum);
	pSld->Slider->setMaximum(_pCamera->_cProperties[i]->_maximum);
	pSld->Slider->setValue(_pCamera->_cProperties[i]->_value);
	QObject::connect(pSld->Slider, SIGNAL(sliderMoved(int)), this, SLOT(OnMovedSlider(int)));
	QObject::connect(pSld->Slider, SIGNAL(valueChanged(int)), this, SLOT(OnMovedSlider(int)));
	break;
    }
    
    pSld->Property = _pCamera->_cProperties[i]->_id;

    _PropertySliders.push_back( pSld );
  }
}
Ejemplo n.º 2
0
bool WaveformRendererSignalBase::init() {
    deleteControls();

    //create controls
    m_pLowFilterControlObject = new ControlObjectThread(
            m_waveformRenderer->getGroup(),"filterLow");
    m_pMidFilterControlObject = new ControlObjectThread(
            m_waveformRenderer->getGroup(),"filterMid");
    m_pHighFilterControlObject = new ControlObjectThread(
            m_waveformRenderer->getGroup(),"filterHigh");
    m_pLowKillControlObject = new ControlObjectThread(
            m_waveformRenderer->getGroup(),"filterLowKill");
    m_pMidKillControlObject = new ControlObjectThread(
            m_waveformRenderer->getGroup(),"filterMidKill");
    m_pHighKillControlObject = new ControlObjectThread(
            m_waveformRenderer->getGroup(),"filterHighKill");

    return onInit();
}
Ejemplo n.º 3
0
WaveformRendererSignalBase::~WaveformRendererSignalBase() {
    deleteControls();
}
Ejemplo n.º 4
0
CPropertiesDialog::~CPropertiesDialog()
{
  g_print("Dialog Destructor calleectord\n");
  deleteControls();
}