QXRD  0.11.16
Public Slots | Signals | Public Member Functions | Private Attributes | List of all members
QxrdPowderPointPropertyDoubleSpinBoxHelper Class Reference

#include <qxrdpowderpointproperty.h>

Inheritance diagram for QxrdPowderPointPropertyDoubleSpinBoxHelper:
Inheritance graph
[legend]
Collaboration diagram for QxrdPowderPointPropertyDoubleSpinBoxHelper:
Collaboration graph
[legend]

Public Slots

void setSubValue (int axis, double value, int index)
 
void setValue (double value)
 

Signals

void subValueChanged (int axis, double value, int index)
 

Public Member Functions

 QxrdPowderPointPropertyDoubleSpinBoxHelper (QDoubleSpinBox *spinBox, QxrdPowderPointProperty *property, int axis)
 
void connect ()
 

Private Attributes

QDoubleSpinBox * m_DoubleSpinBox
 
QxrdPowderPointPropertym_Property
 
int m_Axis
 

Detailed Description

Definition at line 64 of file qxrdpowderpointproperty.h.

Constructor & Destructor Documentation

QxrdPowderPointPropertyDoubleSpinBoxHelper::QxrdPowderPointPropertyDoubleSpinBoxHelper ( QDoubleSpinBox *  spinBox,
QxrdPowderPointProperty property,
int  axis 
)

Definition at line 420 of file qxrdpowderpointproperty.cpp.

421  : QObject(spinBox),
422  m_DoubleSpinBox(spinBox),
423  m_Property(property),
424  m_Axis(axis)
425 {
426 }

Member Function Documentation

void QxrdPowderPointPropertyDoubleSpinBoxHelper::connect ( )

Definition at line 428 of file qxrdpowderpointproperty.cpp.

References CONNECT_CHECK, m_DoubleSpinBox, and setValue().

Referenced by QxrdPowderPointProperty::linkTo().

429 {
430  CONNECT_CHECK(QObject::connect(m_DoubleSpinBox, (void (QDoubleSpinBox::*)(double)) &QDoubleSpinBox::valueChanged,
431  this, &QxrdPowderPointPropertyDoubleSpinBoxHelper::setValue, Qt::DirectConnection));
432 }
#define CONNECT_CHECK(res)
Definition: qcepmacros.h:14

Here is the call graph for this function:

Here is the caller graph for this function:

void QxrdPowderPointPropertyDoubleSpinBoxHelper::setSubValue ( int  axis,
double  value,
int  index 
)
slot

Definition at line 434 of file qxrdpowderpointproperty.cpp.

References QcepProperty::index(), m_Axis, m_DoubleSpinBox, and m_Property.

Referenced by QxrdPowderPointProperty::linkTo().

435 {
436  if (m_Property->index() == index) {
437  if (m_Axis == axis) {
438  if (m_DoubleSpinBox->value() != value) {
439  bool block = m_DoubleSpinBox->blockSignals(true);
440  m_DoubleSpinBox->setValue(value);
441  m_DoubleSpinBox->blockSignals(block);
442  }
443  }
444  }
445 }

Here is the call graph for this function:

Here is the caller graph for this function:

void QxrdPowderPointPropertyDoubleSpinBoxHelper::setValue ( double  value)
slot

Definition at line 447 of file qxrdpowderpointproperty.cpp.

References QcepProperty::incIndex(), m_Axis, m_Property, and subValueChanged().

Referenced by connect().

448 {
449  emit subValueChanged(m_Axis, value, m_Property->incIndex(1));
450 }
void subValueChanged(int axis, double value, int index)
int incIndex(int step)

Here is the call graph for this function:

Here is the caller graph for this function:

void QxrdPowderPointPropertyDoubleSpinBoxHelper::subValueChanged ( int  axis,
double  value,
int  index 
)
signal

Referenced by QxrdPowderPointProperty::linkTo(), and setValue().

Here is the caller graph for this function:

Member Data Documentation

int QxrdPowderPointPropertyDoubleSpinBoxHelper::m_Axis
private

Definition at line 81 of file qxrdpowderpointproperty.h.

Referenced by setSubValue(), and setValue().

QDoubleSpinBox* QxrdPowderPointPropertyDoubleSpinBoxHelper::m_DoubleSpinBox
private

Definition at line 79 of file qxrdpowderpointproperty.h.

Referenced by connect(), and setSubValue().

QxrdPowderPointProperty* QxrdPowderPointPropertyDoubleSpinBoxHelper::m_Property
private

Definition at line 80 of file qxrdpowderpointproperty.h.

Referenced by setSubValue(), and setValue().


The documentation for this class was generated from the following files: