Version: 8.3.0
YACS::HMI::IntEditor Class Reference

#include <ValueDelegate.hxx>

Inheritance diagram for YACS::HMI::IntEditor:
Collaboration diagram for YACS::HMI::IntEditor:

Public Member Functions

 IntEditor (Subject *subject, const ValueDelegate *delegate, int column=0, QWidget *parent=0)
 
virtual ~IntEditor ()
 
virtual QString GetStrValue ()
 
virtual void setData (QVariant val)
 
- Public Member Functions inherited from YACS::HMI::GenericEditor
 GenericEditor ()
 
virtual ~GenericEditor ()
 
virtual void setSubject (Subject *subject)
 
virtual void setColumn (int column)
 
virtual void setDelegate (const ValueDelegate *delegate)
 
virtual SubjectgetSubject ()
 
virtual int getColumnInSubject ()
 
virtual bool firstSetData ()
 

Additional Inherited Members

- Protected Attributes inherited from YACS::HMI::GenericEditor
Subject_subject
 
int _column
 
const ValueDelegate_delegate
 
bool _first
 

Detailed Description

Definition at line 88 of file ValueDelegate.hxx.

Constructor & Destructor Documentation

IntEditor::IntEditor ( Subject subject,
const ValueDelegate delegate,
int  column = 0,
QWidget parent = 0 
)

Definition at line 166 of file ValueDelegate.cxx.

References YACS::HMI::GenericEditor::setColumn(), YACS::HMI::GenericEditor::setDelegate(), and YACS::HMI::GenericEditor::setSubject().

170  : QSpinBox(parent), GenericEditor()
171 {
172  setMinimum(INT_MIN);
173  setMaximum(INT_MAX);
174  setSubject(subject);
175  setDelegate(delegate);
176  setColumn(column);
177 }
IntEditor::~IntEditor ( )
virtual

Definition at line 179 of file ValueDelegate.cxx.

180 {
181 }

Member Function Documentation

QString IntEditor::GetStrValue ( )
virtual

Reimplemented from YACS::HMI::GenericEditor.

Definition at line 183 of file ValueDelegate.cxx.

184 {
185  QString str;
186  str.setNum(value());
187  return str;
188 }
void IntEditor::setData ( QVariant  val)
virtual

Reimplemented from YACS::HMI::GenericEditor.

Definition at line 190 of file ValueDelegate.cxx.

References DEBTRACE.

191 {
192  DEBTRACE("IntEditor::setData");
193  DEBTRACE(val.canConvert<int>());
194  setValue(val.toInt());
195 }

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