Version: 8.3.0
YACS::HMI::TableSwitch Class Reference

#include <TableSwitch.hxx>

Inheritance diagram for YACS::HMI::TableSwitch:
Collaboration diagram for YACS::HMI::TableSwitch:

Public Member Functions

 TableSwitch (QWidget *parent=0)
 
 ~TableSwitch ()
 
virtual void setEditableCase (bool isEditable)
 
virtual void adjustColumns ()
 

Detailed Description

Definition at line 29 of file TableSwitch.hxx.

Constructor & Destructor Documentation

TableSwitch::TableSwitch ( QWidget parent = 0)

Definition at line 32 of file TableSwitch.cxx.

References DEBTRACE.

33 {
34  DEBTRACE("TableSwitch::TableSwitch");
35  setupUi(this);
36  if (tv_nodes->horizontalHeader())
37  tv_nodes->horizontalHeader()->setStretchLastSection(true);
38 }
TableSwitch::~TableSwitch ( )

Definition at line 40 of file TableSwitch.cxx.

References DEBTRACE.

41 {
42  DEBTRACE("TableSwitch::~TableSwitch");
43 }

Member Function Documentation

void TableSwitch::adjustColumns ( )
virtual

Definition at line 57 of file TableSwitch.cxx.

References DEBTRACE, YACS::HMI::YLabel, and YACS::HMI::YType.

Referenced by YACS::HMI::EditionSwitch::synchronize().

58 {
59  DEBTRACE("TableSwitch::adjustColumns");
60  if (!tv_nodes->isColumnHidden(YLabel))
61  tv_nodes->resizeColumnToContents(YLabel);
62  if (!tv_nodes->isColumnHidden(YType))
63  tv_nodes->resizeColumnToContents(YType);
64 }
void TableSwitch::setEditableCase ( bool  isEditable)
virtual

Definition at line 45 of file TableSwitch.cxx.

References DEBTRACE, YACS::HMI::YType, and YACS::HMI::YValue.

Referenced by YACS::HMI::EditionSwitch::EditionSwitch().

46 {
47  DEBTRACE("TableSwitch::setEditablePorts " << isEditable);
48 
49  tv_nodes->setColumnHidden(YType, true);
50  tv_nodes->setColumnHidden(YValue, false);
51 
52  if (tv_nodes->verticalHeader())
53  tv_nodes->verticalHeader()->setVisible(false);
54 
55 }

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