#include <jobpropertyitemnodes.h>
Public Slots | |
void | set (const QString &nodes) |
void | onChildChanged () |
Signals | |
void | itemChanged (const QString &nodes) |
Public Member Functions | |
JobPropertyItemNodes (JobPropertyModel *model, JobPropertyItem *parent=0) | |
virtual | ~JobPropertyItemNodes () |
virtual bool | setData (int column, const QVariant &value) |
virtual void | createCustomContextMenu (QWidget *parent, const QPoint &pos) |
virtual QWidget * | createEditor (QWidget *parent, const QObject *target, const char *receiver) const |
virtual void | updateEditorContents (QWidget *editor) |
virtual void | updateValue (QWidget *editor) |
virtual QString | toString () |
virtual bool | deleteChild (int row) |
virtual void | addNode () |
virtual void | update () |
Private Attributes | |
QString | _nodes |
La classe
Definition at line 19 of file jobpropertyitemnodes.h.
JobPropertyItemNodes::JobPropertyItemNodes | ( | JobPropertyModel * | model, | |
JobPropertyItem * | parent = 0 | |||
) |
Construct a JobPropertyItemNodes
model | the model this property is in | |
parent | parent of this item |
Definition at line 23 of file jobpropertyitemnodes.cpp.
References JobPropertyItem::_name, JobPropertyItem::data(), JobPropertyItem::itemData, JobPropertyItem::parentItem, JobPropertyItem::setHaveContextMenu(), and JobPropertyItem::setReadOnly().
JobPropertyItemNodes::~JobPropertyItemNodes | ( | ) | [virtual] |
Destroy this item and its children
Definition at line 38 of file jobpropertyitemnodes.cpp.
References JobPropertyItem::childItems.
bool JobPropertyItemNodes::setData | ( | int | column, | |
const QVariant & | value | |||
) | [virtual] |
Set the specified data in the specified column
column | the index of the column where to set the data in | |
value | value to set |
Reimplemented from JobPropertyItem.
Definition at line 49 of file jobpropertyitemnodes.cpp.
void JobPropertyItemNodes::createCustomContextMenu | ( | QWidget * | parent, | |
const QPoint & | pos | |||
) | [virtual] |
Create a custom context menu.
parent | parent widget | |
pos | position where the context menu was requested |
Reimplemented from JobPropertyItem.
Definition at line 157 of file jobpropertyitemnodes.cpp.
References addNode().
QWidget * JobPropertyItemNodes::createEditor | ( | QWidget * | parent, | |
const QObject * | target, | |||
const char * | receiver | |||
) | const [virtual] |
Create an editor for this item
parent | parent widget | |
target | object to emit a signal to when the value has changed | |
receiver | method of the target object to connect to |
Implements JobPropertyItem.
Definition at line 63 of file jobpropertyitemnodes.cpp.
void JobPropertyItemNodes::updateEditorContents | ( | QWidget * | editor | ) | [virtual] |
Update the content of the editor
editor | the editor widget |
Implements JobPropertyItem.
Definition at line 75 of file jobpropertyitemnodes.cpp.
void JobPropertyItemNodes::updateValue | ( | QWidget * | editor | ) | [virtual] |
Update the value of the item from the editor
editor | the editor widget |
Implements JobPropertyItem.
Definition at line 85 of file jobpropertyitemnodes.cpp.
QString JobPropertyItemNodes::toString | ( | ) | [virtual] |
Convert the item value to a string
Definition at line 146 of file jobpropertyitemnodes.cpp.
References _nodes.
Referenced by deleteChild(), and update().
bool JobPropertyItemNodes::deleteChild | ( | int | row | ) | [virtual] |
Delete the specified child
row | index of the child to delete |
Reimplemented from JobPropertyItem.
Definition at line 188 of file jobpropertyitemnodes.cpp.
References _nodes, JobPropertyItem::childItems, itemChanged(), toString(), and update().
void JobPropertyItemNodes::addNode | ( | ) | [virtual] |
Add a Node to this item
Definition at line 172 of file jobpropertyitemnodes.cpp.
References JobPropertyItem::_model, JobPropertyItem::childItems, JobPropertyModel::emitLayoutAboutToBeChanged(), JobPropertyModel::emitLayoutChanged(), itemChanged(), and onChildChanged().
Referenced by createCustomContextMenu().
void JobPropertyItemNodes::update | ( | ) | [virtual] |
Update the content of this item using the value of the children.
Definition at line 130 of file jobpropertyitemnodes.cpp.
References _nodes, JobPropertyItem::childItems, and toString().
Referenced by deleteChild(), and onChildChanged().
void JobPropertyItemNodes::set | ( | const QString & | str | ) | [slot] |
Set the value of this item
str | the string to parse to set the value of this item. |
Definition at line 95 of file jobpropertyitemnodes.cpp.
References JobPropertyItem::_model, _nodes, JobPropertyItem::childItems, JobPropertyModel::emitLayoutAboutToBeChanged(), JobPropertyModel::emitLayoutChanged(), itemChanged(), onChildChanged(), and JobPropertyItemNode::set().
void JobPropertyItemNodes::onChildChanged | ( | ) | [slot] |
Slot called when a child has changed
str | value of the child |
Definition at line 121 of file jobpropertyitemnodes.cpp.
References _nodes, itemChanged(), and update().
void JobPropertyItemNodes::itemChanged | ( | const QString & | nodes | ) | [signal] |
Signal emitted when the item has changed
Referenced by addNode(), deleteChild(), onChildChanged(), and set().
QString JobPropertyItemNodes::_nodes [private] |
Definition at line 47 of file jobpropertyitemnodes.h.
Referenced by deleteChild(), onChildChanged(), set(), toString(), and update().